Start Emacs daemon on shell init for instant emacsclient

Daemon starts in the background when a new shell opens so 'e' always
connects to an existing server rather than launching a new instance.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-04-29 15:37:57 -04:00
parent 7a82a6b8f8
commit 668df75efb

View File

@@ -45,6 +45,11 @@ eval "$(keychain --eval --quiet github git)"
# direnv hook
eval "$(direnv hook zsh)"
# Start Emacs daemon if not already running
if ! emacsclient -e nil &>/dev/null; then
emacs --daemon &>/dev/null &
fi
echo -ne '\e[1 q'
export NVM_DIR="$HOME/.nvm"