What is Pico?Pico is a file editor used on UNIX systems. It is invoked by the command pico filename, where filename is replaced with the name of your file.Editing commands are invoked by control key sequences (i.e. pressing the control key and another key simultaneously or, on a Macintosh, pressing the Escape key twice, then another key). Several menu-like status lines at the bottom of the screen show which commands are active at any given time. Key strokes that do not constitute control key sequences are entered as text at the current cursor position. Cursor Movement:You can move your cursor by using the arrow keys; you may also use any of the following editing commands:
Saving a File:You can save the file you are working on by using the Ctrl-o (write out) command. If you exit Pico by using the Ctrl-x (exit) command, you will be given a chance to save the file.Deleting Text:Ctrl-d Delete the character that the cursor is onCtrl-k Delete the line that the cursor is on Ctrl-u Restores last line that was deleted Cutting and Pasting:You can mark text for cutting and pasting by using the Ctrl-^ command. After entering this command, move the cursor to highlight the text you wish to cut. Then use Ctrl-u to paste it.Searching:You can search for a given text by using the Ctrl-w command. The search is NOT case sensitive. After entering the command, you will be prompted for the text for which you want to search. If you press Enter at this point, Pico will repeat the last search. All searches start at the current cursor position and wrap around to the beginning of the file.To move to the last line in the file, type Ctrl-w (where is), Ctrl-v (last line). To move to the first line of the file type Ctrl-w (Whereis), Ctrl-y (first line). |
Justifying Text:The justify command, Ctrl-j, will remove extra white space and new lines to make lines as equal in length as possible. It operates on the paragraph where the cursor is currently positioned. Pico defines a paragraph as text separated by a blank line or a line starting with a blank or tab.By default, Pico 'wraps' lines at 80 characters. It will not break text in the middle of a word, however, but will go back to the most previous white space. This default can be overridden by starting Pico with the -w option. When this is in effect, lines too long to be displayed on the screen will have a '$' in the column furthest to the right. Spell Checking:Pico includes an elementary spell check function which can be invoked with Ctrl-t. It will flag words it cannot find and give you a chance to edit them, but will not suggest a correct spelling or allow you to customize the dictionary. You can also use ispell, a more sophisticated spell checker, on any file. At the command prompt, type ispell filename , where "filename" is the name of the file you want to spell check.Help:Online help is available with the Ctrl-g (help) command. It invokes a short but fairly complete document that you can page through. The command line options are discussed more thoroughly in the man page. To see the man page for Pico, enter man pico at the command prompt.Command Line Options:The following command line options are available for use when Pico is invoked (e.g. pico -w filename):
Miscellaneous:Ctrl-c will report the current cursor position in the buffer by both line number and character at the bottom of the screen.Files are read into Pico with Ctrl-r and written with Ctrl-o. After either of these commands, you can enter Ctrl-t (list files) to invoke the file browser. The file browser will allow you to step through the directory structure, see a listing of all files in a given directory, copy files, rename files, and delete files.
|