- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- .exrc keymapping for vi
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-15-2007 02:44 AM
03-15-2007 02:44 AM
The issue seems to only exist on my 11.11 servers as the 11.23 installs work great.
Any ideas ?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-15-2007 02:52 AM
03-15-2007 02:52 AM
Re: .exrc keymapping for vi
:map shows that the mappings were loaded.
For example:
map #5 :set number
On 11.11
when I hit F5 I get garbage.
On 11.23
Same emulator
F5 works.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-15-2007 08:51 AM
03-15-2007 08:51 AM
Re: .exrc keymapping for vi
What terminal emulator are you using and what kind of terminal it is configured to emulate?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-15-2007 09:41 AM
03-15-2007 09:41 AM
Re: .exrc keymapping for vi
Doublechecked stty and such as well.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-15-2007 02:39 PM
03-15-2007 02:39 PM
Solutionmap ^[P x
which means: ESC P (typed very quickly) will be interpreted by vi as x, and the x command deletes 1 character. The curses name for this code is dch1 (man terminfo) but for a vt100, the code is ^[E[1P. So by looking at the vi command in .exrc, you can reverse engineer the terminal type by the mapped keystrokes. The untic command will show the codes for the various keys:
untic vt220
untic hp
Someone may have replaced yojur $HOME/.exrc with one that matches your terminal. The standard .exrc file is found in /usr/newconfig/etc/skel
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-16-2007 01:41 AM
03-16-2007 01:41 AM
Re: .exrc keymapping for vi
Here is the scenario.
copy /etc/newconfig/etc/skel/.exrc to $HOME on both an PA and IA server ( both newly installed resently ).
edit .exrc and add "map #5 :set nu" in both .
On the IA all works.
On the PA no luck.
I do see that the untick info on the PA is different from the untick info on the IA.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-16-2007 07:04 AM
03-16-2007 07:04 AM
Re: .exrc keymapping for vi
> On the IA all works.
> On the PA no luck.
> I do see that the untick info on the PA is different from the untick info on the IA.
The map #5 directive is used to set the action based on softkey f5 on the keyboard. What the f5 key transmits is VERY dependent on whether the emulator had it's f-keys reprogrammed (like Glance and SAM and swinstall may do). I believe most of the menu tools mentioned leave the keys in their default state, so vi's ability to recognize the f5 key depends on what it sees for the curses code kf5. The default softkey codes for all HP terminals are:
ESC followed by p q r s t u v w for keys 1 2 3 4 5 6 7 8 respectively. So untic hp | grep kf5 shows ESC t. Now vi is looking at the $TERM value when it searches for keymapping. If TERM=hp (or any of the HP terminals), then pressing f5 sends ESC t and vi sees the two letter code for the kf5 curses code, then uses map #5 to select the action.
Now very important: are you testing on a normal connection, Xwindows or using the console? The console (unfortunately) has been really messed up with GSP/MP code in the last couple of years. No matter what model the console terminal is, the GSP/MP overrides TERM.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-03-2007 09:48 AM
04-03-2007 09:48 AM
Re: .exrc keymapping for vi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-03-2007 09:54 AM
04-03-2007 09:54 AM