0

What does the following section do in the tmux config file?

# remap prefix
unbind C-b
set -g prefix C-a
bind C-a send-prefix

It seems to me the unbind removes the default C-a as prefix. But then how do the other two work? (Also, is the last line necessary?)

1
  • It remaps the prefix from C-b to C-a - but I can't tell you the exact meaning of each line.
    – Panki
    Commented Apr 28, 2020 at 7:49

1 Answer 1

1

This sequence changes the prefix from C-b to C-a and also moves the default send-prefix binding from C-b to C-a.

unbind C-b

Remove the default C-b binding which is for send-prefix. This was present so C-b C-b sent a C-b to the application inside tmux.

set -g prefix C-a

Set the prefix to C-a instead of the default C-b.

bind C-a send-prefix

Bind C-a to send-prefix, so that C-a C-a sends a C-a to the application inside tmux.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .