Using Mac OS X, I noticed my arrow key not working in vi editor. This is really annoying when it works on all other Operating systems…
Here’s the solution for those who has arrow key not working in vi / vim for Mac OS:-
Go to your home directory, mine is at /Users/myname/
Open your .profile and add TERM=linux at the first line of the file.
Save and quit
type source .profile and enter
Congratulations! You just fixed the arrow key problem in vi editor.
Also, here is a great writeup on the screen command:
http://www.bangmoney.org/presentations/screen.html