Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add '/', '?', and 'I' bindings to vim-normal mode #1760

Merged
merged 1 commit into from Feb 26, 2024

Conversation

mwpastore
Copy link
Contributor

Add 'I' binding to vim-normal mode (a la 'A' introduced in #1697) to jump into vim-insert mode at the beginning of the search input.

Also add '/' and '?' bindings to vim-normal mode to clear the search input and jump into vim-insert mode. This mimics the UX in e.g. set -o vi (bash) or bindkey -v (zsh) mode when you are using 'k' and 'j' to browse history lines and can type '/' or '?' to start a new search. (In a perfect world it would target the search in the forward or backward range starting at your current position in the history, but this is a reasonable first step.)

Checks

  • I am happy for maintainers to push small adjustments to this PR, to speed up the review cycle
  • I have checked that there are no existing pull requests for the same thing

Add 'I' binding to vim-normal mode (a la 'A' introduced in atuinsh#1697) to
jump into vim-insert mode at the beginning of the search input.

Also add '/' and '?' bindings to vim-normal mode to clear the search
input and jump into vim-insert mode. This mimics the UX in e.g. `set -o
vi` (bash) or `bindkey -v` (zsh) mode when you are using 'k' and 'j' to
browse history lines and can type '/' or '?' to start a new search. (In
a perfect world it would target the search in the forward or backward
range starting at your current position in the history, but this is a
reasonable first step.)
Copy link
Member

@ellie ellie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me! Thank you

Seeing as this is your first time contributing, if you would like a holographic contributors-only Atuin sticker, then please fill out this form!

We do also have a Discord if you'd like to ask any questions, or just fancy hanging out!

@ellie ellie merged commit 43a1d3a into atuinsh:main Feb 26, 2024
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants