Skip to main content
Added powerline as an extra.
Source Link

Tmux has an option to have the #{pane_current_path} as a name for the current pane in the status line. This is great but has two short falls for me:

  1. $HOME is not displayed as ~.
  2. I only really need the last directory name, not the full path from /. So, for example /home/ook/thingy/src would only be displayed as either src or ~/t/src.

Is there a Tmux command that does this?

Bonus points if it works with powerline as well.

Tmux has an option to have the #{pane_current_path} as a name for the current pane in the status line. This is great but has two short falls for me:

  1. $HOME is not displayed as ~.
  2. I only really need the last directory name, not the full path from /.

Is there a Tmux command that does this?

Tmux has an option to have the #{pane_current_path} as a name for the current pane in the status line. This is great but has two short falls for me:

  1. $HOME is not displayed as ~.
  2. I only really need the last directory name, not the full path from /. So, for example /home/ook/thingy/src would only be displayed as either src or ~/t/src.

Is there a Tmux command that does this?

Bonus points if it works with powerline as well.

Source Link

tmux status line and current path format

Tmux has an option to have the #{pane_current_path} as a name for the current pane in the status line. This is great but has two short falls for me:

  1. $HOME is not displayed as ~.
  2. I only really need the last directory name, not the full path from /.

Is there a Tmux command that does this?