Support multiple chars shorthand eg: -ff file --filefrom file#396
Support multiple chars shorthand eg: -ff file --filefrom file#396timandy wants to merge 3 commits intospf13:masterfrom
Conversation
|
I'm not sure these changes really fit into the spirit of the pflag library. The changes proposed here deviate from POSIX and introduce ambiguities. If you want something like this, I would almost recommend sticking to the standard flag library which allows you do handle flags like this more easily without deviating from POSIX conventions. flag.StringVar(&from, "ff", "", "usage")
flag.StringVar(&from, "fromfile", "", "usage") |
|
go asm use no-standard flag, I want to use this lib resolve asm args, befor pass to it. .\asm.exe --help
usage: asm [options] file.s ...
Flags:
-D value
predefined symbol with optional simple value -D=identifier=value; can be set multiple times
-I value
include directory; can be set multiple times
-S print assembly and machine code
-V print version and exit
-d value
enable debugging settings; try -d help
-debug
dump instructions as they are parsed
-dynlink
support references to Go symbols defined in other shared libraries
-e no limit on number of errors reported
-gensymabis
write symbol ABI information to output file, don't assemble
-linkshared
generate code that will be linked against Go shared libraries
-o string
output file; default foo.o for /a/b/c/foo.s as first argument
-p string
set expected package import to path (default "<unlinkable>")
-shared
generate code that can be linked into a shared library
-spectre list
enable spectre mitigations in list (all, ret)
-trimpath string
remove prefix from recorded source file paths
-v print debug output |
|
All standard go tooling ( |
|
This might be helpful depending on what you're trying to do: https://github.com/spf13/pflag?tab=readme-ov-file#supporting-go-flags-when-using-pflag |
Support multiple chars shorthand.
eg:
-ff file
--filefrom file
some commit cherry-picked from #175 .