Editing text

Another major part of running science applications is likely to be editing text files, be they scripts, programs, input files, or notes on how to do all of the above! You may think that choosing a text editor is a simple matter but you'd be wrong - flame wars have been going on since before you were born about which editor is better. The classic argument is vi vs. Emacs, and both of these are installed on our machines. However your author doesn't endorse either of them, as he grew up using Macintosh systems and therefore believes in using GUIs (XEmacs doesn't count).

For most users I recommend using Geany, which is a programmers editor and lightweight IDE - you can access a shell directly in the editor if you wish. It supports syntax highlighting and many other useful features such as column editing, code folding, and has a large selection of plugins to add additional features.

The default Geany interface. If you prefer, the side and bottom bars can be hidden using options in the View menu.
You can switch through various different functions on the left and bottom areas, including enabling a console.

To make Geany your default editor, right click on a text file in the Files application and 'Get Properties'. Then select the 'Open With' tab, select Geany, and click 'Set as default'.

For quick edits the default GEdit (Text Editor) application is OK, but it's very cut-down and probably not good for heavy-duty work. Some old-school users like to use nEdit which remains available, but it's showing its age and there is nothing it can do that Geany can't.

Some useful tips for using Geany:

  • to edit columns of text, hold down ctrl while selecting
  • to open hidden files (dot files) click the 'More Options' triangle in the Open… dialog and check 'Show hidden files'
  • you can open a file from the shell by typing 'geany file.txt'
public/teaching-linux-systems/editing_text.txt · Last modified: 2017/07/18 16:18 by Robert Ryans

Back to Top Sitemap News