dotfiles/.local/bin/scripts/emacstty

8 lines
160 B
Bash
Executable File

#!/bin/sh
# Emacs in the terminal
pgrep --full "emacs --daemon" >/dev/null || emacs --daemon
emacsclient --create-frame --tty "$@"
exit=$?
stty sane
exit $exit