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