blob: 8f811b789b63cf325afe5c71562b625b0674485b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
#!/usr/bin/env sh
case "$(printf "new\nstop\nrestart\neshell\nmail" | dmenu -p "eserver: ")" in
"restart")
systemctl --user restart emacs;
notify-send "eselect: Restarted Emacs server";;
"stop")
systemctl --user stop emacs;
notify-send "eselect: Halted Emacs server";;
"new")
notify-send "eselect: Launching Emacs";
emacsclient -c -a "emacs";;
"eshell")
notify-send "eselect: Launching Eshell";
emacsclient -c -a "emacs" --eval '(progn (eshell) (delete-other-windows))';;
"mail")
notify-send "eselect: Launching notmuch";
emacsclient -c -a "emacs" --eval '(progn (notmuch) (delete-other-windows))';;
esac
|