diff options
| author | Jeff Carr <[email protected]> | 2019-05-25 16:00:33 -0700 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2019-05-25 16:00:33 -0700 |
| commit | 8fe85f0af271c8cbfa4e5735f7136923dab357f8 (patch) | |
| tree | f48b4bfcbbd543410129409a5fd1abf900d14b25 /debug.go | |
| parent | 7b601a8e689ab4bc657f730f23c2c785b2fe7846 (diff) | |
pass the VM to the buttons in the VM tab
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'debug.go')
| -rw-r--r-- | debug.go | 11 |
1 files changed, 9 insertions, 2 deletions
@@ -79,9 +79,14 @@ func addDebuggingButtons(vbox *ui.Box, custom func(*ButtonMap)) { func runPingClick(b *ButtonMap) { log.Println("runPingClick START") + log.Println("runTestExecClick b.VM", b.VM) + hostname := "localhost" + if (b.VM != nil) { + hostname = b.VM.Hostname + } spew.Dump(b) var tmp []string - tmp = append(tmp, "xterm", "-e", "ping localhost") + tmp = append(tmp, "xterm", "-e", "ping " + hostname + ";bash") runCommand(tmp) log.Println("runPingClick END") } @@ -91,7 +96,7 @@ func runTestExecClick(b *ButtonMap) { if runtime.GOOS == "linux" { go runSimpleCommand("xterm -report-fonts") } else if runtime.GOOS == "windows" { - go runSimpleCommand("cmd.exe") + go runSimpleCommand("mintty.exe") } else { go runSimpleCommand("xterm") } @@ -115,6 +120,8 @@ func runCommand(cmdArgs []string) { process.Start() log.Println("runXterm process.Wait()") process.Wait() + log.Println("runXterm NEED TO CHECK THE TIME HERE TO SEE IF THIS WORKED") + log.Println("runXterm OTHERWISE INFORM THE USER") log.Println("runXterm END") log.Println("runXterm END") log.Println("runXterm END") |
