0

I often run a Linux guest on a Windows host, to let me use the Bash command line (through SSH and port forwarding). When I am on a full Ubuntu environment I like to use something such as notify-send to let me know when a task is finished:

./runlongtask.sh && notify-send "long task finished"

Is there any way to have similar functionality such that I can do that from inside Putty (which has SSHd to the guest Linux instance) and the notification appears on the Windows desktop even if I am in another program?

From my Mac days I am aware of Growl and the fact that it had a network protocol - did this actually get anywhere, or is there a newer cross-platform solution that would let me send an alert from an SSH session on one machine to a Desktop on another?

(I don't want to use X11 for this)

3
  • "I don't want to use X11 for this" - Can I ask why? Feb 29, 2012 at 16:33
  • @grawity Isn't X11 a pretty heavyweight requirement for displaying a notification on Windows?
    – Daniel Beck
    Feb 29, 2012 at 16:44
  • @Grawity Because the guest OS doesn't have the X11 bits and pieces installed on it and I'd rather not add it just to tell me when a script has finished.
    – Rich
    Mar 1, 2012 at 6:54

2 Answers 2

2

Growl exists on Windows, too.

To send notifications from Linux, install gntp-send, or hack something together using one of many GNTP modules.

3
  • Thanks - sadly getting gntp-send to actually build is proving impossible (if I follow the instructions to the letter, the makefile doesn't exist; if I use the autogen script, then it fails with the wrong version of autoconf - it needs 2.65 and Centos 6.2 only has 2.63) - thanks anyway :)
    – Rich
    Mar 1, 2012 at 8:02
  • @Rich: See if you can get any of those Perl modules installed from CPAN, and I might write a short notifier script. Mar 1, 2012 at 8:26
  • I've tried but not got anywhere - I have no knowledge of PERL and CPAN, but I am a Java programmer - your mentioning of the gntp protocol made me look for a Java library, so I'm going to use one of those. Thanks again for your proactive support!
    – Rich
    Mar 2, 2012 at 7:51
0

If you are having trouble building gntp-send due to autoconf issues it might be easier to just build a copy of my fork since it doesn't depend on autoconf. I'm not sure what features mattn has added but for basic usage it should be sufficient.

https://github.com/psinnott/gntp-send

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .