60 likes | 98 Views
C151 Multi-User Operating Systems. Editors. Text Editors. Pico Emacs Xemacs – a GUI-based version of Emacs . vi – a mostly terminal-based text editor, very reliable. vim – (vi improved) – a GUI-based version of vi. vi.
E N D
Text Editors • Pico • Emacs • Xemacs – a GUI-based version of Emacs. • vi – a mostly terminal-based text editor, very reliable. • vim – (vi improved) – a GUI-based version of vi.
vi • A text editor, written by Bill Joy in 1976. Short for Visual Interface. • It enables fast, simple, and effective text editing mostly based on simple key bindings. • It provides fast and convenient moving around files and between files. • One must learn a good number of commands to be proficient in vi.
vi modes • vi works in two modes: insert mode and command mode. • Command mode: allows you to do global operations like saving the file, searching for a string and replacing it. • Insert mode: Everything you type in the text. • Vi is started with command mode • Switching modes • ifrom command mode to insert mode • Escfrom insert mode to command mode
Vi Commands • Open a file (new or exitsting one) vi file_name • Save a file :w<Return> • Exit vi (without saving the file) :q!<Return> • Exit vi (and save the file) :wq<Return> :x<Return>
Reading Assignment • Chapter 6