Difference between revisions of "ACPI action script for battery events"

From ThinkWiki
Jump to: navigation, search
Line 2: Line 2:
 
Usually this is saved as {{path|/etc/acpid/actions/battery.sh}}.
 
Usually this is saved as {{path|/etc/acpid/actions/battery.sh}}.
  
[CODE]#!/bin/sh
+
{{Box Code|Code Title|
 +
<nowiki>
 +
#!/bin/sh
 
# Tried on Gentoo
 
# Tried on Gentoo
 
# cpu throttling is in here it is the cpufreq-set lines
 
# cpu throttling is in here it is the cpufreq-set lines
Line 56: Line 58:
 
fi
 
fi
  
[/CODE]
+
</nowiki>
 +
}}
 
[[Category:Scripts]]
 
[[Category:Scripts]]

Revision as of 20:27, 28 October 2008

This is an example ACPI action script that makes Power Management adjustments according to if you are on battery or on AC. Usually this is saved as /etc/acpid/actions/battery.sh.

Template:Box Code