flagon-io/hello

public

Greets people from the command line. The sample repository for g1t.

Add a --wave flag #68

Mergedg1t merged into maing1t-agenton g1t

Approved by g1t-agent

ResolvedAdd a --wave flag#67

Merged into main by g1t automatically, once it was ready, · ac45e10

syntaqxopened this pull request with g1t-agent

I added a --wave flag that prints o/ on its own line after the greeting. cargo test -q passes, and running --wave Ada prints Hi, Ada! then o/.

I added a wave: bool option, the parsing for the flag, a small wave() helper in src/lib.rs that returns "o/", and tests for both. src/main.rs prints it after the greeting lines. It prints before the --bye goodbye when both flags are given, which is a choice the issue didn't specify.

The greeting itself is untouched. main.rs already builds it with greeting_in, which the rename in #66 does not touch. So the flag doesn't depend on the name that PR is changing.

I asked the agent on #66 which name to use. It had not answered when I finished, and the question was still undelivered. Its PR renames greet to hail and farewell to part, though its title says greet() and part(). Because I didn't use either name, #66 and this PR should merge without a conflict in the code. Both change src/lib.rs and src/main.rs, but in different places. I did not check that against a merged tree.

I opened no issues or comments.

syntaqxmarked this ready for review·
g1trequested a review from g1t-agent·
g1t-agentapproved these changes

Read the diff and src/main.rs, and ran cargo test -q. All 12 tests pass.

The --wave flag parses and defaults to false. main.rs prints o/ on its own line after the greeting lines and before the --bye goodbye. The flag only uses greeting_in, which main.rs already depended on, so it adds no dependency on the function name that #66 is renaming.

Two things for the maintainer:

  • The issue asked the author to ask #66's agent which name to use. By their own account the question went unanswered. Nothing in this change uses greet or greeting, so I see no conflict risk beyond textual overlap in lib.rs and main.rs. The author did not check that against a merged tree.
  • The ordering of --wave and --bye is a choice the issue didn't specify. The wave comes first, which reads fine.

Reviewed by a g1t agent on Claude Sonnet 5.5.

g1tadded this to the merge queue·
g1twas taken out of the merge queue. Its combined state could not be built or checked: #68 does not merge cleanly with the default branch: src/main.rs conflict.·
g1tsent g1t-agent back to fix the failed checks·
g1trequested a review from g1t-agent·
g1t-agentapproved these changes

Read the diff and the surrounding code, and ran cargo test -q. All tests pass. The flag is parsed, wave() returns o/, and main.rs prints it on its own line after the greeting lines and before the --bye goodbye. It is skipped under --quiet, which matches the other output. The change builds only on greeting_in, which the rename in #66 does not touch. The head already contains the hail/part names from #66, and the merged tree compiles with these changes.

Two non-blocking notes:

  • With --times N the wave prints once, after all N greetings. That is reasonable, but it is unspecified.
  • The PR says the rename question to the #66 agent was never delivered. The change doesn't depend on the answer, so this does not block merging.

Reviewed by a g1t agent on Claude Sonnet 5.5.

g1tadded this to the merge queue·
g1tmerged this·

Sign in to comment.