Skip to content

Commit

Permalink
enable auto download and install after package add
Browse files Browse the repository at this point in the history
  • Loading branch information
kwindrem committed Mar 4, 2024
1 parent a4aaacd commit c28ef5d
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 11 deletions.
20 changes: 11 additions & 9 deletions PackageManager.py
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,7 @@
# GetAutoAddOk (class method)
# SetAutoAddOk (class method)
# AutoInstallOk (class method)
# UpdateDoNotInstall ()
# SetAutoInstallOk ()
# InstallVersionCheck ()
# UpdateGitHubVersionClass
# UpdateGitHubVersion (thread)
Expand Down Expand Up @@ -1178,7 +1178,7 @@ def RemoveDbusService (self):
# GetAutoAddOk (class method)
# SetAutoAddOk (class method)
# AutoInstallOk (class method)
# UpdateDoNotInstall ()
# SetAutoInstallOk ()
# InstallVersionCheck ()
#
# Globals:
Expand Down Expand Up @@ -1262,10 +1262,10 @@ def SetAutoAddOk (cls, packageName, state):
open (flagFile, 'a').close()


def UpdateDoNotInstall (self, state):
def SetAutoInstallOk (self, state):
packageName = self.PackageName
if packageName == None:
logging.error ("UpdateDoNotInstall - no packageName")
logging.error ("SetAutoInstallOk - no packageName")
return

# if package options directory exists set/clear auto install flag
Expand Down Expand Up @@ -1659,9 +1659,11 @@ def AddPackage ( cls, packageName=None, gitHubUser=None, gitHubBranch=None, sour
if source == 'GUI':
DbusIf.SetGuiEditAction ( '' )
DbusIf.UpdateStatus ( message = "", where='Editor')
# package added from the GUI (aka, manually)
# allow auto adds
PackageClass.SetAutoAddOk (packageName, True)

# allow auto adds and auto installs
PackageClass.SetAutoAddOk (packageName, True)
package.SetAutoInstallOk (True)

else:
if source == 'GUI':
DbusIf.UpdateStatus ( message=packageName + " already exists - choose another name", where=reportStatusTo, logLevel=WARNING )
Expand Down Expand Up @@ -2486,11 +2488,11 @@ def InstallPackage ( self, packageName=None, source=None , direction='install' )
sendStatusTo = 'Editor'
# uninstall sets the uninstall flag file to prevent auto install
if direction == 'uninstall':
package.UpdateDoNotInstall (False)
package.SetAutoInstallOk (True)
logging.warning (packageName + " was manually uninstalled - auto install for that package will be skipped")
# manual install removes the flag file
else:
package.UpdateDoNotInstall (True)
package.SetAutoInstallOk (False)
logging.warning (packageName + " was manually installed - allowing auto install for that package")
elif source == 'AUTO':
sendStatusTo = 'PmStatus'
Expand Down
2 changes: 1 addition & 1 deletion blindInstall/SetupHelperVersion
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v6.9
v6.10
4 changes: 4 additions & 0 deletions changes
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
v6.10:
enable auto download and install after package add
previously, packagew would not auto install if uninstalled manually

v6.9:
fixed: file uninstall fails if extracted from setup script
removed PackageManager download delays
Expand Down
Binary file modified venus-data-UninstallPackages.tgz
Binary file not shown.
Binary file modified venus-data.tgz
Binary file not shown.
2 changes: 1 addition & 1 deletion version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v6.9
v6.10

0 comments on commit c28ef5d

Please sign in to comment.