Changing the command executed when pressing Suspend button
Robert McWilliam
rmcw at allmail.net
Wed Jan 2 02:11:10 UTC 2008
On 01/01/08 20:02:11, Giuseppe Torelli wrote:
> On Jan 1, 2008 6:31 PM, Robert McWilliam <rmcw at allmail.net> wrote:
> > In /etc/acpi
> gt[xarchiver]$ ls /etc/acpi/suspend.d/
<snip>
> Ehm, can you tell me which one I executed? And also what shall I
> change to have executed "sudo pm-suspend"?
I should point out that my understanding of this is a bit vague and comes from
playing with it more than anything. As far as I've figured: apcid gets acpi
events from the hardware, then looks for a matching event in /etc/acpi/events
and that event file directs what to execute, which is usually one of the
scripts in /etc/acpi
As far as I can tell the contents of suspend.d/ are called from prepare.sh,
which is used in sleep.sh and hibernate.sh, so it isn't actually anything in
there that you want to change.
I'm not entirely sure what pm-suspend does but I suspect it replaces the
existing suspend to RAM or disk procedure. Sleep is suspend to RAM and
hibernate is suspend to disk so replace the contents of either sleep.sh or
hibernate.sh with a call to pm-suspend [1]. Alternatively you could probably
put the call directly in the event file you want to trigger the pm-suspend
call.
Given that I am not entirely sure of this advice please be careful to keep
backups of files before changing them so things can be put back if they break
horribly :)
Robert
[1] I don't think you'll need the sudo
________________________________________________________
Robert McWilliam rmcw at allmail.net www.ormiret.com
We have enough youth. How about a fountain of smart?
More information about the xubuntu-devel
mailing list