I use the Ctrl+B command prefix in tmux, however this clashes with Ctrl+B in less, which is used for scrolling up a file.How can I get this to work? Do I have to set a different command prefix in tmux? I really don't want to have to learn new key bindings if I can avoid it.
Using Ctrl+B in less within tmux
tmux
Obviously you can't have two keys that do the same thing when both programs are listening. Tmux is going to get it first. You didn't specify which set of key bindings you don't want to re-learn, but you have to do something different because the same key is used for both apps.If you only use it occationally in less you can just pass the real thing on by hit Ctrl+BB (that's Ctrl-B twice) in tmux to pass on a single Ctrl-B to the app in the current pane.If you want to change the tmux binding to be something else (say like Ctrl+A like screen) you can add this to your `~/.tmux.conf file:unbind C-bset -g prefix C-aIf you want to use something else for less, the G key is usually bound to go to the top of the file already, so no changes necessary. If that change doesn't suit you, you can rebind keys using lesskey.