0

I have set the default shell to bash and have

set -o vi
alias vi=vim

set in the ~/.bash_profile. I also have With this configuration - and apparently some additional special sauce my prior laptop gave me automatic key repeats when editing bash history. E.g. hitting "h" and keepign it depressed would travel leftwards in the current line as long as the key were depressed.

But on a newly configured mac the auto-repeat does not work on the set -o vi commandline. It does however work when in vi itself.

How can this be fixed in set -o vi mode?

5
  • What do you have in ~/.inputrc? I also guess that some unexpected behaviour is related to using .bash_profile instead of .bashrc Aug 21, 2021 at 18:20
  • On this "newly created Mac", have you disabled key popups? I disabled those so long ago I don't remember if the h key has alternatives. Aug 21, 2021 at 18:37
  • @MarcWilson For "disabling key popups" do you mean this apple.stackexchange.com/a/332770/55242 ? Aug 21, 2021 at 18:53
  • Yeah, that uselessness. Aside... I tested in ksh (what I normally use) and bash, and it works as the OP said with popups disabled. What does the key do in insert mode on the command line? Aug 21, 2021 at 19:27
  • @MarcWilson that seems to work : would you like to make it an answer? Aug 21, 2021 at 21:40

1 Answer 1

2

To have full use of repeating characters, disable Apple's press-and-hold support as detailed here: https://apple.stackexchange.com/a/332770/55242

Most likely it works in vim because vim changes the terminal mode, while bash does not.

You must log in to answer this question.

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