I installed gnome-vim in Ubuntu, and it can use mouse to scroll automatically. So I wonder how to make this work in my iMac and HPCC (CentOS 6.6).
add set mouse=a, then save and quit
Now you can use mouse to scroll in Vim, it’s more convenient than using ctrl+d or ctrl+u.
Besides this command, my .vimrc also contains set number and set ruler.
The number will give the number of the line. It likes that you do nl file.txt > nl_file.txt, but it doesn’t change the file. The ruler will give the position of the prompt in Vim at the bottom right corner, which is good for the following sed or awk processing.