mirror of https://github.com/spf13/cobra.git
Add Parent FlagSet
Signed-off-by: fahed dorgaa <fahed.dorgaa@gmail.com>
This commit is contained in:
parent
0580724b5f
commit
0c653d6e38
|
@ -1672,7 +1672,7 @@ func (c *Command) Parent() *Command {
|
||||||
func (c *Command) mergePersistentFlags() {
|
func (c *Command) mergePersistentFlags() {
|
||||||
c.updateParentsPflags()
|
c.updateParentsPflags()
|
||||||
c.Flags().AddFlagSet(c.PersistentFlags())
|
c.Flags().AddFlagSet(c.PersistentFlags())
|
||||||
c.Flags().AddFlagSet(c.parentsPflags)
|
c.Flags().AddParentFlagSet(c.parentsPflags)
|
||||||
}
|
}
|
||||||
|
|
||||||
// updateParentsPflags updates c.parentsPflags by adding
|
// updateParentsPflags updates c.parentsPflags by adding
|
||||||
|
|
Loading…
Reference in New Issue