Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Is there any way to customize the vi editor keys in Solaris Unix?

share|improve this question

migrated from stackoverflow.com Apr 1 '10 at 10:44

This question came from our site for professional and enthusiast programmers.

    
Why would you want to do that? If you find it too hard/alien to use, try a different editor. Changing the defaults will be a pain whenever you work on a vanilla solaris! –  lexu Apr 1 '10 at 7:45
add comment

2 Answers

Solaris uses vi; customization setting go in your ~/.exrc file and are read on startup.

You can map editor keys with the map command (:map <key> <command>). You can remap keys that are already used for other things, so be careful not to disable something you'll need. Note that there are frequently other layers (e.g., X) that can map keys, so look out for conflict there as well.

share|improve this answer
add comment

You can remap keys using http://vimdoc.sourceforge.net/htmldoc/map.html

place these commands in you .vimrc or /etc/vim/vimrc to take effect everytime you use vim. (I hope this applies to solaris as well)

share|improve this answer
1  
it applies to vim, but not necessarily vi. vim is often but not always used as a replacement for vi. –  quack quixote May 13 '10 at 14:23
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.