I just noticed that I couldn't use emacs from within screen at work. Whenever I pressed control-H to open a help screen, emacs would delete a character. This is not the normal operation. It turns out that both my terminfo and /etc/screenrc were "broken" by someone else who thought they were being useful. Idiots.
Here's how I fixed stuff so delete means \e[3~, backspace means ^? and ^H means ^H. The output of "tput kbs | od" was 010 (^H in octal), not 177 (^? in octal). To correct this, I altered my terminfo database.
Translate the local termcap info into terminfo source with captoinfo (or alegedly, "tic -I").
captoinfo -e screen > ~/.terminfo/s/screen.ti
tic ~/.terminfo/s/screen.ti
# ~/.screenrc bindkey -d -k kb
Re:^H
jjore on 2007-04-06T21:56:53
Yes, I'm aware there's some history where ^H means backspace but that doesn't seem to be appropriate on any system I'm using these days. I'm not sure that any typical emacs using OS should be redefining ^H away.
I don't really know the history on this. I'm sure it all goes back to some glass terminals and who was more popular in a particular year.