7

In tmux, pressing prefix + , prompts you to rename the current window:

The (rename-window) prompt is automatically populated with the current window name -- in this case, zsh.

I would rather the the (rename-window) prompt not be pre-populated with the current window name because more times than not, I end up deleting the current window name before typing the new one.

Is there a tmux option or plugin that can make the (rename-window) prompt empty by default?

12

The tmux command for prefix + , can be seen in the list of command, which is displayed when you press prefix + ?

Default should look like this:

bind-key , command-prompt -I #W "rename-window '%%'"

Just cut off the '-I #W' part from there to get the empty value as default suggestion when renaming.

That is, put this line in your tmux.conf:

bind-key , command-prompt "rename-window '%%'"

and reload the tmux config/ restart the tmux

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.