We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 77d181a commit a5e9bd5Copy full SHA for a5e9bd5
cmd/limactl/shell.go
@@ -70,6 +70,10 @@ func newShellCommand() *cobra.Command {
70
func shellAction(cmd *cobra.Command, args []string) error {
71
ctx := cmd.Context()
72
flags := cmd.Flags()
73
+ tty, err := flags.GetBool("tty")
74
+ if err != nil {
75
+ return err
76
+ }
77
// simulate the behavior of double dash
78
newArg := []string{}
79
if len(args) >= 2 && args[1] == "--" {
@@ -106,8 +110,8 @@ func shellAction(cmd *cobra.Command, args []string) error {
106
110
return err
107
111
}
108
112
109
- if !flags.Changed("start") {
- startNow, err = askWhetherToStart()
113
+ if tty && !flags.Changed("start") {
114
+ startNow, err = askWhetherToStart(cmd)
115
if err != nil {
116
117
0 commit comments