Notify user about remote login

About

With ssh one can login remotely into a desktop. Wouldn't it be nice if we got a nice little update about this login? A tiny notification maybe? Well that's what I needed, and there seemed nothing like it in the repo's. So here it is! I have been learning python for a few weeks now, and this seemed like a good excercise. This script checks the output of the system 'who' command (every 5s) and sends a notification if there's a *new* user logged in.

Usage

Make sure you've got python and notify-send (libnotify-bin).

Run it:

python path/to/notify-login-2.0.py

Add it to autostart:

For GNOME users: In System -> Preferences -> Sessions add 'python /path/to/notify-login.py' as the command.

XFCE users can add this through Setting -> Autostarted Applications

*Update*

Updated based on feedback from ubuntu forums http://ubuntuforums.org/showthread.php?t=1091743

1. Added feature to disable notification on local logins.

2. Added notification on logoff