diff options
| author | Jeff Carr <[email protected]> | 2025-10-07 08:00:16 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-10-07 08:00:16 -0500 |
| commit | f46ce34f817930945fd5de53a8cdf4a10b62bded (patch) | |
| tree | a67b2e3af0d0ab478c67c87b27a84951604fd419 | |
| parent | 7d24a00f52238bf6e6298c1e62d7c2bf11b67edd (diff) | |
more things moving away from shell
| -rw-r--r-- | apt.go | 12 |
1 files changed, 4 insertions, 8 deletions
@@ -5,14 +5,14 @@ package debian import ( "github.com/go-cmd/cmd" - "go.wit.com/lib/gui/shell" + "go.wit.com/lib/fhelp" "go.wit.com/log" ) func AptInstall(pkgname string) (*cmd.Status, error) { cmd := []string{"apt-get", "install", "-y", pkgname} log.Info("Running:", cmd) - return shell.RunRealtimeError(cmd) + return fhelp.RunRealtimeError(cmd) } func AptInstallOrExit(pkgname string) error { @@ -28,7 +28,7 @@ func AptRemove(pkgname string) (*cmd.Status, error) { } cmd := []string{"apt-get", "remove", "-y", pkgname} log.Info("Running:", cmd) - return shell.RunRealtimeError(cmd) + return fhelp.RunRealtimeError(cmd) } func AptRemoveOrExit(pkgname string) error { @@ -48,12 +48,8 @@ func AptUpdate() error { cmd = append(cmd, "-o", "Dir::Etc::sourceparts=/dev/null") cmd = append(cmd, "-o", "APT::Get::List-Cleanup=0") log.Info("Running:", cmd) - if _, err := shell.RunRealtimeError(cmd); err != nil { + if _, err := fhelp.RunRealtimeError(cmd); err != nil { return err } - - // if found := me.machine.FindInstalledByName("wit-tools"); found == nil { - // AptInstall("wit-tools") - // } return nil } |
