mirror of
https://github.com/m-housh/dotfiles.git
synced 2026-02-14 06:12:34 +00:00
Added go.nvim, updated ts script to accept a session argument
This commit is contained in:
@@ -1,4 +1,14 @@
|
||||
#!/bin/sh
|
||||
|
||||
session=$(tmux list-sessions -F \#S | gum filter --placeholder "Pick a session...")
|
||||
tmux switch-client -t "$session" || tmux attach -t "$session"
|
||||
session=${1}
|
||||
|
||||
if [ -z "$session" ]; then
|
||||
session=$(tmux list-sessions -F \#S | gum filter --placeholder "Pick a session...")
|
||||
tmux switch-client -t "$session" || tmux attach -t "$session"
|
||||
else
|
||||
if [ ! -z "$(tmux list-sessions -F \#S | grep $session)" ]; then
|
||||
tmux switch-client -t "$session" || tmux attach -t "$session"
|
||||
else
|
||||
echo "No session found for: $session"
|
||||
fi
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user