emacs 23, dbus, and libnotify

A new major version of emacs is out, and it includes dbus support. This is great, because it means we can do things like this:(require ‘dbus)(defun send-desktop-notification (summary body timeout) “call notification-daemon method METHOD with ARGS over dbus" (dbus-call-method :session ; use the session (not system) bus “org.freedesktop.Notifications” ; service name “/org/freedesktop/Notifications” ; path name “org.freedesktop.Notifications” “Notify” ; Method “emacs" 0 ““ summary body ‘(:array) ‘(:array :signature “{sv}") ‘:int32 timeout))(defun pw/compile-notify (buffer message) (send-desktop-notification “emacs compile” message 0))(setq compilation-finish-function ‘pw/compile-notify)Add this to your .
Read more