[tmux] Automatically rename sessions
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
# Automatically rename new sessions to the basename of the current directory
|
||||
set-hook -g session-created 'run-shell "tmux rename-session -t #{session_name} $(basename #{pane_current_path})"'
|
||||
|
||||
# Also rename when attaching to a session (optional)
|
||||
set-hook -g client-session-changed 'run-shell "tmux rename-session -t #{session_name} $(basename #{pane_current_path})"'
|
||||
Reference in New Issue
Block a user