Last active
July 2, 2022 10:13
-
-
Save gelbehexe/a4a22e0cef83ad5b60cc7d14058247d3 to your computer and use it in GitHub Desktop.
tmux bash alias respectively function
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# to store in '.bashrc.d/tmux.sh' or somewhere else in '.bashrc' | |
tx() { | |
if [[ -z "$1" ]]; then | |
echo "Missing session name" | |
return 1; | |
fi | |
tmux a -t "$1" || tmux new -s "$1" | |
} | |
alias txls="tmux ls" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment