lenovo_fix 576 B

123456789101112131415161718
  1. #!/usr/bin/openrc-run
  2. command="PYTHONUNBUFFERED=1 /opt/lenovo_fix/venv/bin/python3 /opt/lenovo_fix/lenovo_fix.py"
  3. pidfile=${pidfile-/var/run/lenovo_fix.pid}
  4. description="Stop Intel throttling"
  5. start() {
  6. ebegin "Starting Throttled daemon"
  7. start-stop-daemon --quiet --background --start --exec $command \
  8. --make-pidfile --pidfile $pidfile -- ""
  9. eend $? "Failed to start Throttled daemon"
  10. }
  11. stop() {
  12. ebegin "Stopping Throttled daemon"
  13. start-stop-daemon --quiet --stop --pidfile $pidfile --signal QUIT
  14. eend $? "Failed to stop Throttled daemon"
  15. }