joe - the easy alternative to vi

Joe is a very simple editor to use, and is very similar to the Borland range of programming editors. Moving around, inserting and deleting text all behave as you would expect them to, so the only thing you really need to know is how to exit and save (Ctrl-K X).

However it is also a very powerful editor. Listed below are those commands I find I use frequently.

BASIC COMMANDS

Ctrl-C          Exit without saving
Ctrl-K X        Exit and save
Ctrl-K D        Save (and remain in editor)
Ctrl-K H        Enable/disable built-in help

EDITING

Ctrl-Y          Delete line
Ctrl-J          Delete to end of line
Ctrl-K J        Reformat paragraph
Ctrl-_          Undo - can be done multiple times
		(On some terminals Ctrl-Shift-Underscore is required)

SEARCH AND REPLACE

Ctrl-K F        Find (and optionally replace)
Ctrl-L          Repeat last find
Ctrl-K L        Go to line number <n>

BLOCK OPERATIONS

Ctrl-K B        Mark start of block
Ctrl-K K        Mark end of block
Ctrl-K C        Copy block to current cursor pos
Ctrl-K M        Move block to current cursor pos
Ctrl-K W        Write block to file
Ctrl-K Y        Delete block
Ctrl-K R	Read in a file and insert at current cursor pos
		(use TAB for automatic file name completion)

MACROS

Ctrl-K [ <n>	Start recording macro <n> (0..9)
Ctrl-K ]        Stop recording macro
Ctrl-K <n>      Play macro <n>

MULTIPLE FILES (can specify multiple filenames on the command line)

Ctrl-K P        Go to previous file
Ctrl-K N        Go to next file
Ctrl-K I        Zoom current window to full screen, or back again
Ctrl-K E	Load file into new window

CURSOR MOVEMENT (for terminals which don't have home/end/pgup/pgdn)

Ctrl-A          Start of line
Ctrl-E          End of line
Ctrl-U          Page up
Ctrl-V          Page down
joe can also use different key bindings. If you invoke it as 'jmacs', 'jstar' or 'jpico' you will get keys corresponding to emacs, wordstar and pico respectively.


Bug workaround: Block highlighting doesn't work for joe 2.8 supplied in Red Hat 4.1, because the format of the termcap file has changed. To work around this problem, edit /etc/termcap and add an extra line as shown in bold below:
...
# From: Eric S. Raymond <esr@snark.thyrsus.com> 9 Nov 1995
linux|linux console:\
	:am:eo:mi:ms:ut:xn:xo:\
	:co#80:it#8:li#25:\
	:so=\E[7m:se=\E[27m:us=\E[36m:ue=\E[m:kH=\E[4~:\
	:&7=^Z:@7=\E[4~:AL=\E[%dL:DC=\E[%dP:DL=\E[%dM:\
	:F1=\E[23~:F2=\E[24~:F3=\E[25~:F4=\E[26~:F5=\E[28~:\
...


Last updated 4 Mar 1997