You are not logged in.

#1 2011-11-03 15:55:11

awayand
Member
Registered: 2009-09-25
Posts: 398

[SOLVED] resume issues with mail-notification

After resuming, I noticed that mail-notification was not working, so I have to restart it everytime. Any way to do this automatically?

I put this into /etc/pm/sleep.d/10mail-notification:

#!/bin/bash
case $1 in
    hibernate)
        echo "Hey guy, we are going to suspend to disk!"
        ;;
    suspend)
        echo "Oh, this time we are doing a suspend to RAM. Cool!"
        ;;
    thaw)
        echo "oh, suspend to disk is over, we are resuming..."
        ;;
    resume)
        echo "hey, the suspend to RAM seems to be over..."
	mail-notification -q && mail-notification
        ;;
    *)  echo "somebody is calling me totally wrong."
        ;;
esac

Issue seems to be solved. Thanks a lot, mrshu!

Last edited by awayand (2011-11-04 11:59:30)

Offline

#2 2011-11-03 19:37:47

mrshu
Member
Registered: 2011-10-26
Posts: 2

Re: [SOLVED] resume issues with mail-notification

It should not be a problem to create a custom hook to restart mail-notification on resume.

In case you are using pm-suspend you can simply customize this script from the wiki

https://wiki.archlinux.org/index.php/Pm … _own_hooks

Offline

#3 2011-11-04 11:54:44

awayand
Member
Registered: 2009-09-25
Posts: 398

Re: [SOLVED] resume issues with mail-notification

thanks for the pointer! Exactly what I was looking for without knowing what I was looking for. smile

Offline

Board footer

Powered by FluxBB