Example #1
0
func MergeFlagSet(fs1, fs2 *gnuflag.FlagSet) *gnuflag.FlagSet {
	fs2.VisitAll(func(flag *gnuflag.Flag) {
		fs1.Var(flag.Value, flag.Name, flag.Usage)
	})
	return fs1
}
Example #2
0
File: cmd.go Project: tsuru/tsuru
func (c *dockerCmd) addMany(fs *gnuflag.FlagSet, val gnuflag.Value, desc string, triggers ...string) {
	for _, t := range triggers {
		fs.Var(val, t, desc)
	}
}