diff options
author | Ryan Kavanagh <rak@rak.ac> | 2023-02-01 13:16:09 -0500 |
---|---|---|
committer | Ryan Kavanagh <rak@rak.ac> | 2023-02-01 13:16:09 -0500 |
commit | f4910cf7238f52256913ebd0302a47a1fc292f9d (patch) | |
tree | 7518427a8c559423bc9d0c7a5f05bf4d47fad52d /bin/executable_tmcg | |
parent | openbsd packages (diff) |
fix bug in tmcg
Diffstat (limited to 'bin/executable_tmcg')
-rwxr-xr-x | bin/executable_tmcg | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/bin/executable_tmcg b/bin/executable_tmcg index d94abbc..5ebb3cf 100755 --- a/bin/executable_tmcg +++ b/bin/executable_tmcg @@ -8,10 +8,12 @@ current_session () { } SESSION=$(current_session) +NEW=1 if [ "x${SESSION}" = "x" ]; then SESSION="irc" tmux new-session -s "${SESSION}" -d + NEW=$? fi if ! tmux switch -t ${SESSION}:catgirl >/dev/null 2>&1; then @@ -21,4 +23,7 @@ if ! tmux switch -t ${SESSION}:catgirl >/dev/null 2>&1; then tmux split-window -t ${SESSION}:catgirl -c '~' catgirl tilde tmux set-option -t ${SESSION}:catgirl remain-on-exit on tmux selectl -t ${SESSION}:catgirl tiled + if test ${NEW} -eq 0; then + tmux kill-window -t ${SESSION}:0 + fi fi |