fish: refactored tmux_sessionizer

This commit is contained in:
Primrose 2024-07-19 23:17:28 +02:00
parent d2d49f9de4
commit d78f5b9043
Signed by: primrose
GPG key ID: 4E887A4CA9714ADA
7 changed files with 74 additions and 78 deletions

View file

@ -0,0 +1,11 @@
function __tmux_register_session \
--description "Register the session, if it's not set yet"
### Effects:
set last /tmp/TMUX_LAST
set this (tmux display-message -p '#S')
if [ ! -f "$last" ]; or [ (cat "$last") != "$tmux_current" ]
echo $this >$last
end
end