Ver código fonte

Merge pull request #68 from PietroCarrara/master

Using '-' doesn't raise an error
J Guerreiro 7 anos atrás
pai
commit
22931a77a3
1 arquivos alterados com 1 adições e 1 exclusões
  1. 1 1
      cmd.go

+ 1 - 1
cmd.go

@@ -152,7 +152,7 @@ func parser() (op string, options []string, packages []string, changedConfig boo
 			}
 		}
 
-		if arg[0] == '-' && arg[1] == '-' {
+		if strings.HasPrefix(arg, "--") {
 			changedConfig = true
 			switch arg {
 			case "--printconfig":