feat: add windows dependencies

This commit is contained in:
Lea Anthony
2018-12-23 15:37:51 +11:00
parent 807f772055
commit 5493e1d4ac
5 changed files with 14 additions and 5 deletions

View File

@@ -11,6 +11,7 @@ type LinuxDistribution int
const (
// Unknown is the catch-all distro
Unknown LinuxDistribution = 0
// Ubuntu distribution
Ubuntu LinuxDistribution = 1
)
@@ -31,7 +32,7 @@ func GetLinuxDistroInfo() *DistroInfo {
lsbRelease := program.FindProgram("lsb_release")
if lsbRelease != nil {
stdout, _, err, _ := lsbRelease.Run("-a")
stdout, _, _, err := lsbRelease.Run("-a")
if err != nil {
return result
}
@@ -72,7 +73,7 @@ func DpkgInstalled(packageName string) (bool, error) {
if dpkg == nil {
return false, fmt.Errorf("cannot check dependencies: dpkg not found")
}
_, _, _, exitCode := dpkg.Run("-L", packageName)
_, _, exitCode, _ := dpkg.Run("-L", packageName)
result = exitCode == 0
return result, nil
}