config run: support for RunFns.Functions and RunFns.Input

- Support specifying RunFns.Functions using the `-i` flag to specify an image
- Parse the function config from key-value arguments specified after ` -- `
- Support reading from stdin / writing to stdout if no arguments are provided
- Table driven tests for parsing flags and args into RunFns structure
This commit is contained in:
Phillip Wittrock
2020-01-15 09:48:29 -08:00
parent 37ee56fc9a
commit a61d478f0d
3 changed files with 384 additions and 13 deletions

View File

@@ -97,6 +97,9 @@ func NewConfigCommand(name string) *cobra.Command {
root.AddCommand(commands.Merge3Command(name))
root.AddCommand(commands.CountCommand(name))
root.AddCommand(commands.RunFnCommand(name))
root.AddCommand(commands.XArgsCommand())
root.AddCommand(commands.WrapCommand())
root.AddCommand(commands.SetCommand(name))
root.AddCommand(commands.ListSettersCommand(name))
root.AddCommand(commands.CreateSetterCommand(name))