Saving commands to a file using Ctrl-x-e
Thursday, 9 March 2023
Add Comment

One very interesting trick that you may not know is that you can type a line of text (presumably a command) on the Linux command line and immediately save it to a file by pressing just three keys. The editor that will open up will depend on your $EDITOR setting that you can view using the command shown below:
$ echo $EDITOR nano
If you prefer to use a different editor, use a command like this before typing or moving back to the command that you want to save:
$ export EDITOR=vi
And don't forget to save this change to your .bashrc (or other start-up file) if you want to make this change permanent. For example:
from Network World https://ift.tt/6k2QGsM
Related
Genrerating Link.... 15 seconds.
Your Link is Ready.
0 Response to "Saving commands to a file using Ctrl-x-e"
Post a Comment