in your term, caping your page-up/down

4 posts in this topic

Does anyone know why vi and other such programs would ignore $TERMCAP?

Basically I've set $TERM to pcansi because it's the closest thing to my terminal, however the /etc/termcap entry for pcansi does not have definitions for page-up/down. I searched through /etc/termcap and didn't find an entry that I liked. When running screen it complains if $TERM is not in the /etc/termcap database. So.. I set $TERM to pcansi to get screen from complaining then I add definitions to $TERMCAP for page-up/downs. The thing is that it seems most programs ignore your $TERMCAP if $TERM is a valid entry. Any ideas on how I get screen not to complain about invalid $TERMs and have programs read my $TERMCAP at the same time? This is really bothering me Modifying anything on my computer isn't an option, unfortunately. For example I'm not going to add a screen.TERM entry or modify /etc/termcap.

Edited May 6, 2010 by SigFLUP

-2

Share this post

Link to post

Share on other sites

Sure its not been configured to use vi style keybindings for the direction keys?

Try hjkl when in edit mode ,if it moves the cursor round it has. I quite like them because it saves taking your hands off the keyboard to move round, but of late lots of stuff has stopped honouring that sort of thing to try and make them more friendly.

Ive been on some oldschool stuff running aix etc that used the hjkl even for terminal useage whatever termcap etc was set to. Smit used to be like that out the box...

You can turn it on and off with a . file edit irrc, rtfm and all that...

I always set termtype to vt102 and export it and leave it at that, but thats because half the stuff I use is so out of date and obsolete it doesnt know anything newer

-2

Share this post

Link to post

Share on other sites

Sure its not been configured to use vi style keybindings for the direction keys?

Try hjkl when in edit mode ,if it moves the cursor round it has. I quite like them because it saves taking your hands off the keyboard to move round, but of late lots of stuff has stopped honouring that sort of thing to try and make them more friendly.

Ive been on some oldschool stuff running aix etc that used the hjkl even for terminal useage whatever termcap etc was set to. Smit used to be like that out the box...

You can turn it on and off with a . file edit irrc, rtfm and all that...

I always set termtype to vt102 and export it and leave it at that, but thats because half the stuff I use is so out of date and obsolete it doesnt know anything newer

yeah hjkl is pretty wicked mate. That always works. I probably should of updated my post- I figured it out. I mis-typed my $TERMCAP variable and it just refused to use it as a result

-1

Share this post

Link to post

Share on other sites

Sure its not been configured to use vi style keybindings for the direction keys?

Try hjkl when in edit mode ,if it moves the cursor round it has. I quite like them because it saves taking your hands off the keyboard to move round, but of late lots of stuff has stopped honouring that sort of thing to try and make them more friendly.

Ive been on some oldschool stuff running aix etc that used the hjkl even for terminal useage whatever termcap etc was set to. Smit used to be like that out the box...

You can turn it on and off with a . file edit irrc, rtfm and all that...

I always set termtype to vt102 and export it and leave it at that, but thats because half the stuff I use is so out of date and obsolete it doesnt know anything newer

Using hjkl for arrows is when your shell is in vi mode. You can set your keybindings to vi or emacs. This has nothing to do with `old school AIX' or `termcap' its a shell setting. (AIX ships with ksh, which is set to vi mode by default):

bash/ksh: set -o vi OR set -o emacs

zsh: bindkey -v OR bindkey -e

Now back to termcap, these days you can get away with TERM=linux, TERM=xterm, or TERM=rxvt for most applications. Sounds like you are having trouble with GNU screen? Try setting your termcap info in your .screenrc (check the man pages for more details, anything vt100 should work).