diff options
Diffstat (limited to 'apt.go')
| -rw-r--r-- | apt.go | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -15,6 +15,10 @@ func (me *Machine) initPackages() { return } + if me.Packages == nil { + me.Packages = new(Packages) + } + // Print the installed packages and their versions for pkg, version := range newP { new1 := new(Package) @@ -37,7 +41,7 @@ func (me *Machine) addNew(name string, version string) bool { return me.Packages.Append(new1) } -func (me *Machine) updatePackages() string { +func (me *Machine) UpdatePackages() string { // Get the list of installed packages for the detected distro newP, err := getPackageList(me.Distro) if err != nil { |
