Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ require (
github.com/spf13/pflag v1.0.10
github.com/spf13/viper v1.21.0
github.com/verda-cloud/verdacloud-sdk-go v1.4.2
github.com/verda-cloud/verdagostack v1.4.1
github.com/verda-cloud/verdagostack v1.4.2
go.yaml.in/yaml/v3 v3.0.4
)

Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -189,8 +189,8 @@ github.com/vbatts/tar-split v0.12.2 h1:w/Y6tjxpeiFMR47yzZPlPj/FcPLpXbTUi/9H7d3CP
github.com/vbatts/tar-split v0.12.2/go.mod h1:eF6B6i6ftWQcDqEn3/iGFRFRo8cBIMSJVOpnNdfTMFA=
github.com/verda-cloud/verdacloud-sdk-go v1.4.2 h1:oVb8fHVQOY+YPuuMYMee9gYCkPTwAw01LmkqxM21T/Y=
github.com/verda-cloud/verdacloud-sdk-go v1.4.2/go.mod h1:pmlpiCL9fTSikZ3qWLJPpHOG0E8PKkQVUX5s4Z+SktY=
github.com/verda-cloud/verdagostack v1.4.1 h1:Jj+15fw+RlBWGuY4dPSbjgLoqS8UKLdQa9RTYeB8VxM=
github.com/verda-cloud/verdagostack v1.4.1/go.mod h1:TuJkNkis787dfJTU//dTKEMTbL/tDWDlgcPPI0WiJgw=
github.com/verda-cloud/verdagostack v1.4.2 h1:JiTBWB+WeFOSPoWO2dBVkP3NyV2tId8OEeJw9MNI32k=
github.com/verda-cloud/verdagostack v1.4.2/go.mod h1:TuJkNkis787dfJTU//dTKEMTbL/tDWDlgcPPI0WiJgw=
github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e h1:JVG44RsyaB9T2KIHavMF/ppJZNG9ZpyihvCd0w101no=
github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e/go.mod h1:RbqR21r5mrJuqunuUZ/Dhy/avygyECGrLceyNeo4LiM=
github.com/yosida95/uritemplate/v3 v3.0.2 h1:Ed3Oyj9yrmi9087+NczuL5BwkIc4wvTb5zIM+UJPGz4=
Expand Down
2 changes: 1 addition & 1 deletion internal/verda-cli/cmd/startupscript/add.go
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ func runAdd(cmd *cobra.Command, f cmdutil.Factory, ioStreams cmdutil.IOStreams,
}
content = string(data)
case 1: // Paste content
content, err = prompter.Editor(ctx, "Script content (Ctrl+D to finish)",
content, err = prompter.Editor(ctx, "Script content",
tui.WithEditorDefault("#!/bin/bash\n\n# Your startup script here\n"),
tui.WithFileExt(".sh"))
if err != nil {
Expand Down
6 changes: 3 additions & 3 deletions internal/verda-cli/cmd/vm/wizard.go
Original file line number Diff line number Diff line change
Expand Up @@ -523,7 +523,7 @@ func stepStorage(getClient clientFunc, cache *apiCache, opts *createOptions) wiz
for i, c := range choices {
labels[i] = c.Label
}
idx, err := prompter.Select(ctx, "Storage", labels)
idx, err := prompter.Select(ctx, "Storage", labels, tui.WithShowHints(true))
if err != nil {
return nil, err
}
Expand Down Expand Up @@ -610,7 +610,7 @@ func stepSSHKeys(getClient clientFunc, opts *createOptions) wizard.Step {
for i, c := range choices {
labels[i] = c.Label
}
indices, err := prompter.MultiSelect(ctx, "SSH keys to inject", labels, tui.WithMinSelections(1))
indices, err := prompter.MultiSelect(ctx, "SSH keys to inject", labels, tui.WithMinSelections(1), tui.WithMultiSelectShowHints(true))
if err != nil {
return nil, err
}
Expand Down Expand Up @@ -692,7 +692,7 @@ func stepStartupScript(getClient clientFunc, opts *createOptions) wizard.Step {
for i, c := range choices {
labels[i] = c.Label
}
idx, err := prompter.Select(ctx, "Startup script (optional)", labels)
idx, err := prompter.Select(ctx, "Startup script (optional)", labels, tui.WithShowHints(true))
if err != nil {
return nil, err
}
Expand Down
10 changes: 5 additions & 5 deletions internal/verda-cli/cmd/vm/wizard_subflows.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ func promptAddSSHKey(ctx context.Context, prompter tui.Prompter, client *verda.C
sourceIdx, err := prompter.Select(ctx, "Public key source", []string{
"Load from file",
"Paste content",
})
}, tui.WithShowHints(true))
if err != nil {
return nil, nil //nolint:nilerr // User canceled.
}
Expand Down Expand Up @@ -127,7 +127,7 @@ func promptSSHKeyFilePath(ctx context.Context, prompter tui.Prompter) (string, e
copy(labels, pubFiles)
labels[len(pubFiles)] = "Enter path manually..."

idx, err := prompter.Select(ctx, "Select public key file", labels)
idx, err := prompter.Select(ctx, "Select public key file", labels, tui.WithShowHints(true))
if err != nil {
return "", err
}
Expand Down Expand Up @@ -208,7 +208,7 @@ func promptAddStartupScript(ctx context.Context, prompter tui.Prompter, client *
sourceIdx, err := prompter.Select(ctx, "Script source", []string{
"Load from file",
"Paste content",
})
}, tui.WithShowHints(true))
if err != nil {
return nil, nil //nolint:nilerr // User canceled or left input blank.
}
Expand All @@ -227,7 +227,7 @@ func promptAddStartupScript(ctx context.Context, prompter tui.Prompter, client *
}
content = string(data)
case 1: // Paste content
content, err = prompter.Editor(ctx, "Script content (Ctrl+D to finish)",
content, err = prompter.Editor(ctx, "Script content",
tui.WithEditorDefault("#!/bin/bash\n\n# Your startup script here\n"),
tui.WithFileExt(".sh"))
if err != nil {
Expand Down Expand Up @@ -343,7 +343,7 @@ func promptAttachExisting(ctx context.Context, prompter tui.Prompter, status tui
}
labels = append(labels, "← Back")

idx, err := prompter.Select(ctx, "Select volume to attach", labels)
idx, err := prompter.Select(ctx, "Select volume to attach", labels, tui.WithShowHints(true))
if err != nil {
return "", nil //nolint:nilerr // User canceled or left input blank.
}
Expand Down