kernelsmith
11/7/2014 - 11:32 PM

irssi irc notifications over ssh & dbus

irssi irc notifications over ssh & dbus

#07-17.26.09 < nsh> locally:
#07-17.26.09 < nsh> (trusty)xeb@localhost:~/code/irssi-libnotify$ ssh -f -N -q -R 1337:localhost:1337 nsh@ch0wn.org && ./notify-listener.py & nc -kl 1337 | while read L; do
#                   DBUS_SESSION_BUS_ADDRESS=unix:abstract=/tmp/dbus-L4FcbXHr0c,guid=3af4775950b0a0e542bf161c5455fea3 dbus-send --session /org/irssi/Irssi org.irssi.Irssi.IrssiNotify
#                   string:"Message from t3hmd4rkw4bs" string:"$L"; done
#07-17.26.37 < nsh> when i just changed the command in notify.pl to: echo "$summary: $message" | nc localhost 1337
#07-17.27.35 < nsh> the messy stuff is just what irssi-notifier.sh does from https://code.google.com/p/irssi-libnotify
#07-17.27.50 < nsh> (after the ssh command)

ssh -f -N -q -R 1337:localhost:1337 nsh@ch0wn.org && ./notify-listener.py & nc -kl 1337 | while read L; do
  DBUS_SESSION_BUS_ADDRESS=unix:abstract=/tmp/dbus-L4FcbXHr0c,guid=3af4775950b0a0e542bf161c5455fea3 dbus-send --session /org/irssi/Irssi org.irssi.Irssi.IrssiNotify
  string:"Message from t3hmd4rkw4bs" string:"$L"
done