Merge pull request #1 from surdeus/master

Parse now returns parsed arguments to make code shorter.
This commit is contained in:
Andreo Parhomenka 2023-06-28 16:12:58 +05:00 committed by GitHub
commit 73d5a2f194
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -25,9 +25,10 @@ type Tool struct {
type Tools map[string] Tool
func (flags *Flags) Parse() {
func (flags *Flags) Parse() []string {
flags.FlagSet.Parse(flags.args)
flags.parsedArgs = flags.FlagSet.Args()
return flags.parsedArgs
}
func (flags *Flags) AllArgs() []string {