home | O'Reilly's CD bookshelfs | FreeBSD | Linux | Cisco | Cisco Exam  


UNIX in a Nutshell: System V Edition

UNIX in a Nutshell: System V EditionSearch this book
Previous: 8.5 Accessing Multiple Files Chapter 8
The Vi Editor
Next: 8.7 Macros
 

8.6 Interacting with UNIX

:r file Read in contents of file after cursor.
:r ! command Read in output from command after current line.
: n r ! command Like above, but place after line n (0 for top of file).
:! command Run command , then return.
! object command Send buffer object to UNIX command ; replace with output.
: n1 , n2 ! command Send lines n1 - n2 to command ; replace with output.
n !! command Send n lines to UNIX command ; replace with output.
!! Repeat last system command.
:sh Create subshell; return to file with EOF .
CTRL-Z Suspend editor, resume with fg (not in all versions).
:so file Read and execute commands from file .


Previous: 8.5 Accessing Multiple Files UNIX in a Nutshell: System V Edition Next: 8.7 Macros
8.5 Accessing Multiple Files Book Index 8.7 Macros

The UNIX CD Bookshelf Navigation The UNIX CD BookshelfUNIX Power ToolsUNIX in a NutshellLearning the vi Editorsed & awkLearning the Korn ShellLearning the UNIX Operating System