MCPcopy Create free account
hub / github.com/OctopusDeploy/cli / NewCmdEnable

Function NewCmdEnable

pkg/cmd/project/enable/enable.go:27–44  ·  view source on GitHub ↗
(f factory.Factory)

Source from the content-addressed store, hash-verified

25}
26
27func NewCmdEnable(f factory.Factory) *cobra.Command {
28 cmd := &cobra.Command{
29 Use: "enable",
30 Short: "Enable a project",
31 Long: "Enable a project in Octopus Deploy",
32 Example: heredoc.Docf("%[1]s project enable", constants.ExecutableName),
33 RunE: func(c *cobra.Command, args []string) error {
34 if len(args) == 0 {
35 args = append(args, "")
36 }
37
38 opts := NewEnableOptions(args, cmd.NewDependencies(f, c))
39 return disableRun(opts)
40 },
41 }
42
43 return cmd
44}
45
46func disableRun(opts *EnableOptions) error {
47 if !opts.NoPrompt {

Callers

nothing calls this directly

Calls 2

NewEnableOptionsFunction · 0.70
disableRunFunction · 0.70

Tested by

no test coverage detected