1 2 3 4 5 6 7
#!/bin/sh if ! pgrep emacs >/dev/null; then emacs --daemon >/dev/null 2>&1 exec notify-send -u low -t 2000 'emacs' ' Emacs daemonized' fi