Skip to content

Commit

Permalink
Snap tag 2.0-beta + governor_override improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
AdnanHodzic committed Feb 3, 2023
1 parent fe21ddf commit 04b8783
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 10 deletions.
3 changes: 1 addition & 2 deletions auto_cpufreq/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
if os.getenv("PKG_MARKER") == "SNAP":
governor_override_state = Path("/var/snap/auto-cpufreq/current/override.pickle")
else:
governor_override_state = Path("/opt/auto-cpufreq/current/override.pickle")
governor_override_state = Path("/opt/auto-cpufreq/override.pickle")

if os.getenv("PKG_MARKER") == "SNAP":
auto_cpufreq_stats_path = Path("/var/snap/auto-cpufreq/current/auto-cpufreq.stats")
Expand Down Expand Up @@ -370,7 +370,6 @@ def deploy_daemon():
bluetooth_disable()

auto_cpufreq_stats_path.touch(exist_ok=True)
governor_override_state.touch(exist_ok=True)

print("\n* Deploy auto-cpufreq install script")
shutil.copy(SCRIPTS_DIR / "auto-cpufreq-install.sh", "/usr/local/bin/auto-cpufreq-install")
Expand Down
1 change: 0 additions & 1 deletion bin/auto-cpufreq
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,6 @@ def main(config, daemon, debug, install, remove, install_performance, live, log,
python_info()
print("")
device_info()
print(f"VALUE {governor_override_state_path}")
if charging():
print("Battery is: charging")
else:
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ def read(name):
return f.read()

# Used for the tar.gz/snap releases
VERSION = "1.9.7"
VERSION = "2.0-beta"

setup(
name="auto-cpufreq",
Expand Down
6 changes: 0 additions & 6 deletions snap/snapcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,6 @@ plugs:
interface: system-files
write:
- /etc/auto-cpufreq.conf
# opt-auto-cpufreq:
# interface: system-files
# write:
# - /opt/auto-cpufreq/override.pickle

apps:
auto-cpufreq:
Expand All @@ -61,15 +57,13 @@ apps:
- system-observe
- hardware-observe
- etc-auto-cpufreq-conf
# - opt-auto-cpufreq
service:
command: usr/bin/snapdaemon
plugs:
- cpu-control
- system-observe
- hardware-observe
- etc-auto-cpufreq-conf
# - opt-auto-cpufreq
environment:
LC_ALL: C.UTF-8
LANG: C.UTF-8
Expand Down

0 comments on commit 04b8783

Please sign in to comment.