3

What I want to do is made C-h not send backwards-delete-char

there is nothing about it in my inputrc files but is shows up in bind -p

  • It is default for both vi and emacs mode, check man readline | grep "C-H" . Try adding "\C-h": "" to your ~/.inputrc file. – user996142 Jun 30 '17 at 16:00
3

C-h is bound to backward-delete-char by default. If you don't like that, bind it to a different command in your .inputrc, e.g.

"\C-h": nop

to make it do nothing.

Note that if your terminal sends C-h for the BackSpace key¹, and C-h is not explicitly bound to an existing command (so not nop), then C-h will execute backward-delete-char.

¹ More precisely, if your terminal's configuration tell applications that this is so. This is the erase character in the stty settings. You can display stty settings by running stty -a.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.