Add basic NFS configure command template

This commit is contained in:
Gregory Kurtzer
2020-12-19 00:40:05 -08:00
parent 7d20130601
commit 2ac2625b29
2 changed files with 28 additions and 0 deletions

View File

@@ -1 +1,8 @@
package nfs
import "github.com/spf13/cobra"
func CobraRunE(cmd *cobra.Command, args []string) error {
return nil
}

View File

@@ -1 +1,22 @@
package nfs
import "github.com/spf13/cobra"
var (
baseCmd = &cobra.Command{
Use: "nfs",
Short: "NFS configuration",
Long: "NFS Config",
RunE: CobraRunE,
}
SetShow bool
)
func init() {
baseCmd.PersistentFlags().BoolVarP(&SetShow, "show", "s", false, "Show configuration (don't update)")
}
// GetRootCommand returns the root cobra.Command for the application.
func GetCommand() *cobra.Command {
return baseCmd
}