You are not logged in.

#1 2014-11-19 22:01:46

balert
Member
Registered: 2012-02-21
Posts: 9

Run script at login, logoff, suspend, wake, ...

I am wondering if there is an elegant solution to run scripts at specific events. For example I would like to run a script that notifies me of pending package updates when i LOG IN to Gnome after wakeup from standby. Also I would like to prevent the machine from suspending or shutting down (just delay it, not totally stop) for finishing the backup first for example. These are my use cases. I would be interested in a elegant solution not limited to the use cases I mentioned. I guess it should be easy to hook into it, but triggering a script at the moment when I sucessfully entered my passwort after wakeup could be little tricky. We are not talking about Gnome login, my Gnome session is already running, just wake up from standby and then unlock.

Offline

#2 2014-11-20 00:50:35

ralvez
Member
From: Canada
Registered: 2005-12-06
Posts: 1,730
Website

Re: Run script at login, logoff, suspend, wake, ...

Well ... I'm not sure about scripts but there is a nice little app in AUR called Yapan. It will put an icon in your tray and every so often it will check if there are updates in pacman. If there are the icon turns red, so you know there are updates.
When you click it, it will open the console, so  you can see (as when your run pacman -Syu) what is going on as you update.
I've seen some small scripts for conky (If you use it) that let you know about updates.

I hope this helps.

R.

Offline

#3 2014-11-20 01:17:57

skunktrader
Member
From: Brisbane, Australia
Registered: 2010-02-14
Posts: 1,681

Re: Run script at login, logoff, suspend, wake, ...

Offline

#4 2014-11-25 11:42:49

balert
Member
Registered: 2012-02-21
Posts: 9

Re: Run script at login, logoff, suspend, wake, ...

Thanks this already helped me a lot. I am just curious if it might be possible to run scripts at GDM successful login time. That is the only thing not yet solved here.

Offline

#5 2014-11-25 13:47:57

qinohe
Member
From: Netherlands
Registered: 2012-06-20
Posts: 1,601

Re: Run script at login, logoff, suspend, wake, ...

I guess GDM already has a solution for that; PreSession PostSession.
Have a look at
https://help.gnome.org/admin/gdm/stable … #scripting
and
http://www.ibiblio.org/oswg/oswg-nightl … /x135.html

Offline

#6 2014-11-25 21:26:05

balert
Member
Registered: 2012-02-21
Posts: 9

Re: Run script at login, logoff, suspend, wake, ...

Thanks, I'll have a look. Guess, this should work!

Offline

Board footer

Powered by FluxBB