Closed gabebw closed 4 years ago
Do you have a second to talk about Our Lord And Savior Ctrl-s?
@gfontenot
1) Thank you for using <kbd>
❤️
2) That's a good idea! Does Ctrl-s interfere with any standard keybindings?
Not sure! I think I learned it from @christoomey, who would certainly know the answer to that.
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
.
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
Which also means you can still use ctrl+a
in vim/zsh/bash/whatever.
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.
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.
That's lovely to hear @christoomey!
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.