Answer: You can always start up an editor immediately to edit the current file being viewed. This will save some time and command typing. The editor is taken from the environment variable VISUAL if defined, or EDITOR if VISUAL is not defined, or defaults to "vi" if neither VISUAL nor EDITOR is defined. I suggest you define your EDITOR first, enter:
$ export EDITOR=vimOR
$ echo 'export EDITOR=vim' >> ~/.bash_profileNow open any file using more or less pager:
$ less myfile.txtOR
$ more ~/some.confNow, to edit a file, hit v key from keyboard. This will start up an editor at current line and file.
No comments:
Post a Comment