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

Function PromptForDotNetConfig

pkg/machinescommon/ssh_common.go:124–144  ·  view source on GitHub ↗
(opts *SshCommonOptions, flags *SshCommonFlags, entityType string)

Source from the content-addressed store, hash-verified

122}
123
124func PromptForDotNetConfig(opts *SshCommonOptions, flags *SshCommonFlags, entityType string) error {
125 if flags.Runtime.Value == "" {
126 selectedRuntime, err := selectors.SelectOptions(opts.Ask, fmt.Sprintf("Select the %s runtime\n", entityType), getTargetRuntimeOptions)
127 if err != nil {
128 return err
129 }
130 flags.Runtime.Value = selectedRuntime.Value
131 }
132
133 if flags.Runtime.Value == SelfContainedCalamari {
134 if flags.Platform.Value == "" {
135 selectedPlatform, err := selectors.SelectOptions(opts.Ask, fmt.Sprintf("Select the %s platform\n", entityType), getTargetPlatformOptions)
136 if err != nil {
137 return err
138 }
139 flags.Platform.Value = selectedPlatform.Value
140 }
141 }
142
143 return nil
144}
145
146func PromptForSshAccount(opts *SshCommonOptions, flags *SshCommonFlags) error {
147 var account accounts.IAccount

Calls 1

SelectOptionsFunction · 0.92