add check for reattach-to-user-namespace
if reattach-to-user-name-space exists, run it, otherwise just run the shell * create login-shell command to perform this check * update tmux.conf to run login-shell instead of reattach-to-user-namespace directly
This commit is contained in:
10
bin/login-shell
Executable file
10
bin/login-shell
Executable file
@@ -0,0 +1,10 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
shell=$(basename "$SHELL")
|
||||
|
||||
# check if reattach-to-user-namespace is available
|
||||
if [ -n "$(command -v reattach-to-user-namespace)" ]; then
|
||||
reattach-to-user-namespace -l "$shell"
|
||||
else
|
||||
exec "$shell -l"
|
||||
fi
|
||||
Reference in New Issue
Block a user