I'd like to fix this frequent problem where the shell on a remote server thinks my terminal's backspace key is ^?
and sometimes it thinks it is ^H
, and happens to be incorrect and outputs the wrong character when I press backspace. If I set it to ^H or ^? with stty erase ^H
or stty erase ^?
in my .bashrc file, and use some other terminal to access the server, it often ends up wrong. So I'm stuck having to manually type stty erase [whatever]
to fix it when I notice the backspace key is wrong.
What I'd like to do is bind both ^?
and ^H
to backspace, because if I can do this, I can just add it to all of my .bashrc files, and it will certainly end this nightmare. Is this possible? If so, how?