diff options
| author | Jeff Carr <[email protected]> | 2024-11-05 01:44:24 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2024-11-05 01:44:24 -0600 |
| commit | a72c700f6336da2dd33d5559c8451ccab97172df (patch) | |
| tree | 8de17ebb874f1e02ebddecbb73dfb8544b645426 /quickCmd.go | |
| parent | d3cc4d6a154680e2ff1463ff2d1d3687fef82c1a (diff) | |
got a temp window to work as a workaround
Diffstat (limited to 'quickCmd.go')
| -rw-r--r-- | quickCmd.go | 50 |
1 files changed, 0 insertions, 50 deletions
diff --git a/quickCmd.go b/quickCmd.go deleted file mode 100644 index a1e8b8e..0000000 --- a/quickCmd.go +++ /dev/null @@ -1,50 +0,0 @@ -package main - -import ( - "os" - - "go.wit.com/lib/gui/repostatus" - "go.wit.com/log" -) - -func doesExist(path string) bool { - if _, err := os.Stat(path); err != nil { - if os.IsNotExist(err) { - return false - } - } - return true -} - -// only errors on bad errors -func quickCmd(fullpath string, cmd []string) bool { - var err error - var b bool - var output string - - if me.autoWorkingPwd.String() != fullpath { - me.autoWorkingPwd.SetValue(fullpath) - } - - if me.autoDryRun.Checked() { - log.Warn("RUN --dry-run", fullpath, cmd) - return false - } else { - log.Warn("RUN:", fullpath, cmd) - } - - err, b, output = repostatus.RunCmd(fullpath, cmd) - if err != nil { - log.Warn("cmd =", cmd) - log.Warn("err =", err) - log.Warn("b =", b) - log.Warn("output =", string(output)) - return false - } else if !b { - log.Warn("b =", b) - log.Warn("output =", string(output)) - return true - } - log.Warn("output = ", string(output)) - return true -} |
