Just like leader_key + C creates a new window inside a session. Is there a similar shortcut for creating a new session ? Currently, I use leader_key + new
Why not just create a keybinding for that in your .tmux.conf?
These two settings let you create/kill a new session when pressing Prefix S (Shift+s) or Prefix K (Shift+k) respectively:
bind S command-prompt -p "New Session:" "new-session -A -s '%%'"
bind K confirm kill-session
Prefix Shift+s will open a command prompt in the status line, asking for a new session name. It will either create a new session with that name or attach to an already existing session by that name.
There are no predefined shortcuts, the only native way to do it is :
Create session: tmux new -s session_name
Ctrl-B + d to detach
Return to your session: tmux attach-session -t session_name
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With