gabebw / dotfiles

:tulip:
https://gabebw.com
230 stars 23 forks source link

Try `Ctrl-b` as tmux prefix #131

Closed gabebw closed 4 years ago

gabebw commented 6 years ago

My current tmux prefix is Ctrl-a. I'd like to use that key combo for its default use: going to the beginning of a line anywhere in the system (even in Vim command mode!). I use Ctrl-e to go to the end of the line all the time, so I'd use Ctrl-a a lot I bet.

gfontenot commented 6 years ago

Do you have a second to talk about Our Lord And Savior Ctrl-s?

gabebw commented 6 years ago

@gfontenot

1) Thank you for using <kbd> ❤️ 2) That's a good idea! Does Ctrl-s interfere with any standard keybindings?

gfontenot commented 6 years ago

Not sure! I think I learned it from @christoomey, who would certainly know the answer to that.

odnoletkov commented 6 years ago

Ctrl-s is the opposite of Ctrl-r in bash/readline history search mode – it selects previous (more recent) match for current query. But it doesn't usually work out of the box because it is also used for terminal flow control – you can fix this with stty -ixon.

teoljungberg commented 6 years ago

I have my prefix set as ctrl+a, and have ctrl+a+a configured in tmux to send ctrl+a to the underlaying program.

https://github.com/teoljungberg/dotfiles/blob/3dfd80fff1feded284278933df3a5ffd56b3d358/tmux.conf#L40

teoljungberg commented 6 years ago

Which also means you can still use ctrl+a in vim/zsh/bash/whatever.

gabebw commented 4 years ago

I just learned that Ctrl-b moves to the beginning of the command line in Vim: https://stackoverflow.com/questions/10201430/how-to-quickly-scroll-to-the-latest-end-of-command-history-in-bash

I have Vim keybindings set (https://github.com/gabebw/dotfiles/blob/f95aba467fb616a5b0cb9481eb85c9589dfeba34/zshrc#L441) at the command line, so I just use standard Vim keys to move around.

I am closing this because that's really all I need.

christoomey commented 4 years ago

Always fun getting notifications on things like this years later 👋 Hi @gabebw, hope all is super great with you. Also, in the nature of the world being tiny, just today I was looking at your fx gem, @teoljungberg. Hoping to be able to use it on a project soon!

You're cool too, @gfontenot.

teoljungberg commented 4 years ago

That's lovely to hear @christoomey!

gabebw commented 4 years ago

Hi Chris, just got a job at Grammarly starting May 19th! I'm excited to start doing more Typescript (and thus #163 is becoming more urgent 😄). I saw you started freelancing recently - I know you'll do well ❤️!