Package: backupninja
Severity: wishlist
Tags: patch

When using backupninja on a laptop, it would be nice to be able to
choose to not run certain jobs when off AC power. I don't want to use
my limited battery power running a backup, I'd rather wait until I
plug the system in.

I have modified backupninja to check if a job is not supposed to be
run on battery power, and if not, if the system is on battery power.
It checks for a "runonbattery" option (which defaults to "yes") in the
main section of each backup job's config file in /etc/backup.d, and
uses "acpi -a" and grep to check the power status.

I'm not sure of the right way to supply a diff, so I will attach
/usr/sbin/backupninja, changed from 0.9.4-6ubuntu4 (on my laptop,
which runs Ubuntu...Debian on my desktop, but I don't run it without
it being plugged in, of course). The changes are the adding of lines
276-291.  Then the default config file should be updated, and
ninjahelper too, I guess, though that's over my head right now.



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to