Skip to content

Commit

Permalink
Merge pull request #575 from ppvnf/patch-47
Browse files Browse the repository at this point in the history
fix: properly update packages: use winget update command
  • Loading branch information
marticliment authored Jan 3, 2023
2 parents a7b76fb + 7333dc5 commit e0a979e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions wingetui/storeEngine.py
Original file line number Diff line number Diff line change
Expand Up @@ -141,9 +141,9 @@ def runInstallation(self) -> None:
if self.progressbar.invertedAppearance(): self.progressbar.setInvertedAppearance(False)
if(self.store.lower() == "winget"):
if self.useId:
self.p = subprocess.Popen(self.adminstr + [wingetHelpers.winget, "install", "-e", "--id", f"{self.packageId}"] + self.version + wingetHelpers.common_params + self.cmdline_args, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, stdin=subprocess.PIPE, shell=True, cwd=sudoLocation, env=os.environ)
self.p = subprocess.Popen(self.adminstr + [wingetHelpers.winget, "upgrade", "-e", "--id", f"{self.packageId}"] + self.version + wingetHelpers.common_params + self.cmdline_args, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, stdin=subprocess.PIPE, shell=True, cwd=sudoLocation, env=os.environ)
else:
self.p = subprocess.Popen(self.adminstr + [wingetHelpers.winget, "install", "-e", "--name", f"{self.programName}"] + self.version + wingetHelpers.common_params + self.cmdline_args, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, stdin=subprocess.PIPE, shell=True, cwd=sudoLocation, env=os.environ)
self.p = subprocess.Popen(self.adminstr + [wingetHelpers.winget, "upgrade", "-e", "--name", f"{self.programName}"] + self.version + wingetHelpers.common_params + self.cmdline_args, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, stdin=subprocess.PIPE, shell=True, cwd=sudoLocation, env=os.environ)
print(self.p.args)
self.t = KillableThread(target=wingetHelpers.installAssistant, args=(self.p, self.finishInstallation, self.addInfoLine, self.counterSignal))
self.t.start()
Expand Down

0 comments on commit e0a979e

Please sign in to comment.