Only query pacman when on arch and not a snap install. (#173)

This commit is contained in:
Marco Vermeulen 2021-02-07 18:26:34 +00:00 committed by GitHub
parent efd03a1d16
commit 50b1e48115
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 2 deletions

View File

@ -60,8 +60,6 @@ dist_name = distro.id()
# display running version of auto-cpufreq
def app_version():
aur_pkg_check = call("pacman -Qs auto-cpufreq > /dev/null", shell=True)
print("auto-cpufreq version:")
# snap package
@ -69,6 +67,7 @@ def app_version():
print(getoutput("echo Snap: $SNAP_VERSION"))
# aur package
elif dist_name in ["arch", "manjaro", "garuda"]:
aur_pkg_check = call("pacman -Qs auto-cpufreq > /dev/null", shell=True)
if aur_pkg_check == 1:
print("Git commit:", check_output(["git", "describe", "--always"]).strip().decode())
else: