Adding a new hook to change the configuration file for upower. The new configuration uses percentages for battery levels and uses power off for the critical battery level action.

This commit is contained in:
Łukasz 'sil2100' Zemczak 2016-03-30 16:21:43 +02:00
commit 47a0bcd26f
2 changed files with 17 additions and 0 deletions

7
debian/changelog vendored
View File

@ -1,3 +1,10 @@
livecd-rootfs (2.394) UNRELEASED; urgency=medium
[ Xavi Garcia ]
* Adding a new hook to change the configuration file for upower.
-- Łukasz 'sil2100' Zemczak <lukasz.zemczak@ubuntu.com> Wed, 30 Mar 2016 16:20:20 +0200
livecd-rootfs (2.393) xenial; urgency=medium
* actually make the /etc/mtab link relative (LP: #1547033)

View File

@ -0,0 +1,10 @@
#! /bin/sh
set -e
echo "Updating upower configuration..."
sed -i 's/^UsePercentageForPolicy=.*/UsePercentageForPolicy=true/' /etc/UPower/UPower.conf
sed -i 's/^CriticalPowerAction=.*/CriticalPowerAction=PowerOff/' /etc/UPower/UPower.conf