mirror of
https://github.com/spf13/cobra
synced 2024-06-28 22:59:07 +00:00
Compare commits
2 commits
07afd387c4
...
161c5d1040
Author | SHA1 | Date | |
---|---|---|---|
|
161c5d1040 | ||
|
03ef288abc |
|
@ -111,6 +111,11 @@ type Command struct {
|
||||||
// command does not define one.
|
// command does not define one.
|
||||||
Version string
|
Version string
|
||||||
|
|
||||||
|
// Data are key/value pairs of arbitrary types that can be used by applications or "plugin" libraries
|
||||||
|
// that wish to store and use data associated with a given command. This data will thus share the same
|
||||||
|
// lifetime as the command itself.
|
||||||
|
Data map[string]any
|
||||||
|
|
||||||
// The *Run functions are executed in the following order:
|
// The *Run functions are executed in the following order:
|
||||||
// * PersistentPreRun()
|
// * PersistentPreRun()
|
||||||
// * PreRun()
|
// * PreRun()
|
||||||
|
|
Loading…
Reference in a new issue