summaryrefslogtreecommitdiff
path: root/parse.go
diff options
context:
space:
mode:
authorAlex Flint <[email protected]>2024-11-04 12:56:12 -0500
committerGitHub <[email protected]>2024-11-04 12:56:12 -0500
commitefb1be7122ca536544533937a831b54111eff19e (patch)
treeb1920fb274548c15efa8c97d2b04cf64c9addcdd /parse.go
parentb218ad854d6817efffffa7f3d2cd3897498b28f6 (diff)
parent51d9bef113c82cff90c5929d28934bb241e1b1df (diff)
Merge pull request #273 from alexflint/pass-dash-dash-through
Passing the no-more-options string "--" twice or more
Diffstat (limited to 'parse.go')
-rw-r--r--parse.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/parse.go b/parse.go
index 172c7cd..d9c73d0 100644
--- a/parse.go
+++ b/parse.go
@@ -615,7 +615,7 @@ func (p *Parser) process(args []string) error {
// must use explicit for loop, not range, because we manipulate i inside the loop
for i := 0; i < len(args); i++ {
arg := args[i]
- if arg == "--" {
+ if arg == "--" && !allpositional {
allpositional = true
continue
}