From 9c14034e396cf0f68dd57a7817c1d184db8e9624 Mon Sep 17 00:00:00 2001 From: Riyyi Date: Wed, 17 Mar 2021 22:41:53 +0100 Subject: [PATCH] Properly spawn emacsclient in a new process --- .local/bin/aliases | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.local/bin/aliases b/.local/bin/aliases index 7641c45..3e0f14f 100755 --- a/.local/bin/aliases +++ b/.local/bin/aliases @@ -7,9 +7,9 @@ depend() { emacs() { # Create new frame (if there isnt one or no file is specified) if [ -z "$(pgrep -f emacsclient.*-c)" ] || [ "$1" = "" ]; then - emacsclient -a '' -c "$@" > /dev/null 2>&1 & + setsid -f emacsclient -a '' -c "$@" > /dev/null 2>&1 else - emacsclient -a '' "$@" > /dev/null 2>&1 & + setsid -f emacsclient -a '' "$@" > /dev/null 2>&1 fi }