Real power users and gurus already know this, but I just ran across it yesterday, and thought it was worth sharing. To scan thru a medium to large size file most people use "less" rather than "more" because you can move backwards as well as forward. The "v" key used in "less" automatically opens the file in the editor of your choice. Make changes, and exit the editor, and you are returned to "less."
This action is dependent on the environment variables EDITOR, or VISUAL. Some distros come with those variables loaded (usually with vi or vim), and in others, such as Debian, you have to load them yourself. Try
Code:
debian64:~$ echo $EDITOR
vim
debian64:~$
or
Code:
debian64:~$ echo $VISUAL
vim
debian64:~$
If you come up blank there,
Code:
$ EDITOR=vim
$ VISUAL=vim
$ export EDITOR VISUAL
If you like it, add those lines to your /etc/profile file.
You could, of course, choose to use nano, pico, emacs, or any other editor.