Files
warewulf/internal/app/wwctl/overlay/mkdir/root.go
2021-12-29 16:11:25 -08:00

27 lines
698 B
Go

package mkdir
import (
"github.com/spf13/cobra"
)
var (
baseCmd = &cobra.Command{
DisableFlagsInUseLine: true,
Use: "mkdir [OPTIONS] OVERLAY_NAME DIRECTORY",
Short: "Create a new directory within an Overlay",
Long: "This command creates a new directory within the Warewulf OVERLAY_NAME.",
RunE: CobraRunE,
Args: cobra.MinimumNArgs(3),
}
PermMode int32
)
func init() {
baseCmd.PersistentFlags().Int32VarP(&PermMode, "mode", "m", 0755, "Permission mode for directory")
}
// GetRootCommand returns the root cobra.Command for the application.
func GetCommand() *cobra.Command {
return baseCmd
}