Skip to content

Preserve standalone dashes as positional arguments - #159

Open
Boulea7 wants to merge 1 commit into
peterbourgon:mainfrom
Boulea7:ln-cx/dash-terminator
Open

Boulea7 wants to merge 1 commit into
peterbourgon:mainfrom
Boulea7:ln-cx/dash-terminator

Conversation

@Boulea7

@Boulea7 Boulea7 commented Sep 29, 2026 •

Copy link
Copy Markdown

Treat a standalone - as the first positional argument, preserving it and the remaining arguments instead of continuing flag parsing. This also prevents a later argument from being selected as a subcommand. Regression tests cover both flag set constructors and keep - working as a flag value.

Local go test -count=1 -race ./... passes. With gofumpt v0.12.0, the full-tree check fails on the same existing formatting difference in ffval/collections.go on unmodified main; the changed files pass. Revive v1.17.0 reports the same three existing warnings on both revisions.

GitHub Actions has not executed the code checks (action_required, zero jobs).

@Boulea7
Boulea7 marked this pull request as ready for review October 1, 2026 22:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant