airshipctl/cmd/workflow.go
2019-05-17 14:37:30 -05:00

24 lines
569 B
Go

package cmd
import (
"io"
"github.com/spf13/cobra"
)
var kubeConfigFilePath string
// NewWorkflowCommand creates a new command for working with argo workflows
func NewWorkflowCommand(out io.Writer, args []string) *cobra.Command {
workflowRootCmd := &cobra.Command{
Use: "workflow",
Short: "access to workflows",
Aliases: []string{"workflows", "wf"},
}
workflowRootCmd.PersistentFlags().StringVar(&kubeConfigFilePath, "kubeconfig", "", "path to kubeconfig")
workflowRootCmd.AddCommand(NewWorkflowListCommand(out, args))
return workflowRootCmd
}