The easiest text editor to learn and use on Discovery is Nano. To use it, enter module load nano
to load the editor and then nano
to open a new file. To open an existing file, enter nano </path/to/file>
(e.g., nano jl.job
).
Like most applications, Nano has default settings but it can be configured by the user to enable or disable features. For example, the default view includes a help menu at the bottom of the editor and does not include line numbers:
The editor features can be changed by setting options in a ~/.nanorc
configuration file. For example, the following configuration file adds line numbers and removes the bottom help menu:
set linenumbers
set nohelp
The editor would then look like this:
The full list of available configuration options can be viewed here. Additionally, improved syntax highlighting for various programming languages can be enabled with the add-ons found here.
Additional resources: