Back UNIX in a Nutshell: Desktop Quick Reference for SV & Solaris 2.0
Table  of  Contents

Preface ................................................................ xiii
Audience ............................................................... xiii
Scope of This Book ...................................................... xiv
Conventions ............................................................. xiv
Acknowledgments .......................................................... xv

Section 1--Introduction ................................................. 1-1
Merging the Traditions .................................................. 1-1
Bundling ................................................................ 1-2
What's in the Quick Ref ................................................. 1-3
Beginner's Guide ........................................................ 1-3
Communication ........................................................... 1-4
Comparisons ............................................................. 1-4
File Management ......................................................... 1-4
Miscellaneous ........................................................... 1-5
Printing ................................................................ 1-5
Programming ............................................................. 1-5
Searching ............................................................... 1-6
Shell Programming ....................................................... 1-6
Storage ................................................................. 1-6
System Status ........................................................... 1-6
Text Processing ......................................................... 1-7
Troff ................................................................... 1-7
Guide for Users of BSD-derived Systems .................................. 1-7

Section 2--UNIX Commands ................................................ 2-1
Alphabetical Summary of Commands ........................................ 2-2

Section 3--The UNIX Shell: An Overview  ................................. 3-1
Introduction to the Shell ............................................... 3-2
Purpose of the Shell .................................................... 3-2
Interactive Use ......................................................... 3-2
Customization of Your UNIX Session ...................................... 3-2
Programming ............................................................. 3-3
Shell Flavors ........................................................... 3-3
Common Features ......................................................... 3-3
Differing Features ...................................................... 3-5

Section 4--The Bourne Shell and Korn Shell  ............................. 4-1
Overview of Features .................................................... 4-2
Syntax .................................................................. 4-2
Special Files ........................................................... 4-2
Filename Metacharacters ................................................. 4-3
Quoting ................................................................. 4-3
Command Forms ........................................................... 4-4
Redirection Forms ....................................................... 4-5
Coprocesses ............................................................. 4-6
Variables ............................................................... 4-7
Variable Substitution ................................................... 4-7
Built-in Shell Variables ................................................ 4-8
Other Shell Variables ................................................... 4-9
Arrays ................................................................. 4-10
Arithmetic Expressions ................................................. 4-10
Operators .............................................................. 4-11
Examples ............................................................... 4-11
Command History ........................................................ 4-11
Line-edit Mode ......................................................... 4-11
The fc Command ......................................................... 4-12
Built-in Commands (Bourne and Korn Shell) .............................. 4-12
Job Control ............................................................ 4-33
Invoking the Shell ..................................................... 4-33
Restricted Shells ...................................................... 4-34

Section 5--The C Shell .................................................. 5-1
Overview of Features .................................................... 5-2
Syntax .................................................................. 5-2
Special Files ........................................................... 5-2
Filename Metacharacters ................................................. 5-2
Quoting ................................................................. 5-3
Command Forms ........................................................... 5-4
Redirection Forms ....................................................... 5-4
Variables ............................................................... 5-5
Variable Substitution ................................................... 5-6
Variable Modifiers ...................................................... 5-6
Predefined Shell Variables .............................................. 5-8
Example .cshrc File ..................................................... 5-9
Environment Variables .................................................. 5-10
Expressions ............................................................ 5-11
Operators .............................................................. 5-11
Examples ............................................................... 5-12
Command History ........................................................ 5-13
Command Substitution ................................................... 5-13
Command Substitution Examples .......................................... 5-13
Word Substitution ...................................................... 5-14
Word Substitution Examples ............................................. 5-14
History Modifiers ...................................................... 5-15
History Modifier Examples .............................................. 5-15
Built-in C Shell Commands .............................................. 5-16
Job Control ............................................................ 5-28
Invoking the Shell ..................................................... 5-29

Section 6--Pattern Matching ............................................. 6-1
Filenames Versus Patterns ............................................... 6-2
Metacharacters, Listed by UNIX Program .................................. 6-2
Metacharacters .......................................................... 6-3
Examples of Searching ................................................... 6-4
Examples of Searching and Replacing ..................................... 6-5

Section 7--The Emacs Editor ............................................. 7-1
Introduction ............................................................ 7-1
Notes on the Tables ..................................................... 7-2
Absolutely Essential Commands ........................................... 7-2
Summary of Commands by Group ............................................ 7-3
File-handling Commands .................................................. 7-3
Cursor Movement Commands ................................................ 7-3
Deletion Commands ....................................................... 7-4
Paragraphs and Regions .................................................. 7-4
Stopping and Undoing Commands ........................................... 7-4
Transposition Commands .................................................. 7-4
Capitalization Commands ................................................. 7-5
Incremental Search Commands ............................................. 7-5
Word Abbreviation Commands .............................................. 7-5
Buffer Manipulation Commands ............................................ 7-5
Window Commands ......................................................... 7-6
Special Shell Characters ................................................ 7-6
Indentation Commands .................................................... 7-6
Centering Commands ...................................................... 7-7
Macro Commands .......................................................... 7-7
Basic Indentation Commands .............................................. 7-7
Detail Information Help Commands ........................................ 7-7
Help Commands ........................................................... 7-8
Summary of Commands by Key .............................................. 7-8
Control-key Sequences ................................................... 7-8
Meta-key Sequences ..................................................... 7-10
Summary of Commands by Name ............................................ 7-11

Section 8--The Vi Editor ................................................ 8-1
Review of Vi Operations ................................................. 8-2
Command-line Syntax ..................................................... 8-2
Command Mode ............................................................ 8-2
Insert Mode ............................................................. 8-2
Syntax of Vi Commands ................................................... 8-3
Status-line Commands .................................................... 8-4
Movement Commands ....................................................... 8-4
Edit Commands ........................................................... 8-6
Saving and Exiting ...................................................... 8-7
Accessing Multiple Files ................................................ 8-7
Interacting with UNIX ................................................... 8-8
Macros .................................................................. 8-8
Miscellaneous Commands .................................................. 8-8
Alphabetical List of Keys ............................................... 8-9
Setting Up Vi .......................................................... 8-11
The :set Command ....................................................... 8-11
Options Used by :set ................................................... 8-11
Example .exrc File ..................................................... 8-14

Section 9--The Ex Editor ................................................ 9-1
Syntax of Ex Commands ................................................... 9-2
Options ................................................................. 9-2
Addresses ............................................................... 9-2
Address Symbols ......................................................... 9-2
Alphabetical Summary of Ex Commands ..................................... 9-3

Section 10--The Sed Editor ............................................. 10-1
Command-line Syntax .................................................... 10-2
Conceptual Overview .................................................... 10-2
Syntax of Sed Commands ................................................. 10-3
Pattern Addressing ..................................................... 10-3
Group Summary of Sed Commands .......................................... 10-4
Alphabetical Summary of Sed Commands ................................... 10-5

Section 11--The Awk Scripting Language ................................. 11-1
Command-line Syntax .................................................... 11-2
Conceptual Overview .................................................... 11-2
Patterns and Procedures ................................................ 11-3
Patterns ............................................................... 11-3
Procedures ............................................................. 11-4
Simple Pattern-Procedure Examples ...................................... 11-4
Awk System Variables ................................................... 11-5
Operators .............................................................. 11-5
Variables and Array Assignments ........................................ 11-6
Group Listing of Awk Commands .......................................... 11-6
Alphabetical Summary of Commands ....................................... 11-7

Section 12--Nroff and Troff ............................................ 12-1
Introduction ........................................................... 12-2
Command-line Invocation ................................................ 12-2
Using the Requests:  An Overview ....................................... 12-3
Common Requests ........................................................ 12-3
Specifying Measurements ................................................ 12-4
Requests That Cause a Line Break ....................................... 12-5
Default Operation of Requests .......................................... 12-5
Group Summary of Requests .............................................. 12-7
Alphabetical Summary of Requests ....................................... 12-9
Escape Sequences ...................................................... 12-19
Predefined Number Registers ........................................... 12-21
Read-only Registers ................................................... 12-21
Read-write Registers .................................................. 12-22
Special Characters .................................................... 12-22

Section 13--mm Macros .................................................. 13-1
Alphabetical Summary of mm Macros ...................................... 13-2
Predefined String Names ............................................... 13-14
Number Registers Used in mm ........................................... 13-14
Other Reserved Macro and String Names ................................. 13-16

Section 14--ms Macros .................................................. 14-1
Alphabetical Summary of ms Macros ...................................... 14-2
Number Registers for Page Layout ....................................... 14-7
Reserved Macro and String Names ........................................ 14-7
Reserved Number Register Names ......................................... 14-8

Section 15--me Macros .................................................. 15-1
Alphabetical Summary of me Macros ...................................... 15-2
Predefined Strings ..................................................... 15-9

Section 16--Preprocessors .............................................. 16-1
Tbl .................................................................... 16-2
General Coding Scheme .................................................. 16-2
Tbl Macros ............................................................. 16-2
Options ................................................................ 16-3
Format ................................................................. 16-3
Data ................................................................... 16-4
A Tbl Example .......................................................... 16-5
Eqn .................................................................... 16-6
Eqn Macros ............................................................. 16-6
Mathematical Characters ................................................ 16-6
Mathematical Text ...................................................... 16-7
Greek Characters ....................................................... 16-7
Diacritical Marks ...................................................... 16-8
Keywords Recognized by Eqn ............................................. 16-8
Precedence ............................................................. 16-9
Eqn Examples .......................................................... 16-10
Pic ................................................................... 16-10
Pic Macros ............................................................ 16-11
Declarations .......................................................... 16-11
Primitives ............................................................ 16-11
Options ............................................................... 16-12
Text .................................................................. 16-13
Object Blocks ......................................................... 16-13
Macros ................................................................ 16-13
Positioning ........................................................... 16-14
Arithmetic Operators .................................................. 16-15
Default Values ........................................................ 16-16
A Pic Example ......................................................... 16-16

Section 17--The SCCS Utility ........................................... 17-1
Overview of Commands ................................................... 17-2
Basic Operation ........................................................ 17-3
Creating an SCCS File .................................................. 17-3
Retrieving a File ...................................................... 17-3
Creating New Releases and Branches ..................................... 17-4
Recording Changes ...................................................... 17-4
Identification Keywords ................................................ 17-5
Data Keywords .......................................................... 17-5
Alphabetical Summary of SCCS Commands .................................. 17-7
sccs and Pseudo-commands .............................................. 17-13

Section 18--The RCS Utility ............................................ 18-1
Overview of Commands ................................................... 18-2
Basic Operation ........................................................ 18-2
General RCS Specifications ............................................. 18-3
Keyword Substitution ................................................... 18-3
Revision Numbering ..................................................... 18-5
Specifying the Date .................................................... 18-5
Specifying States ...................................................... 18-6
Standard Options ....................................................... 18-6
Conversion Guide for SCCS Users ........................................ 18-7
Alphabetical Summary of Commands ....................................... 18-7

Section 19--The make Utility ........................................... 19-1
Command-line Syntax .................................................... 19-2
Description File Lines ................................................. 19-2
Macros ................................................................. 19-3
Internal Macros ........................................................ 19-3
Macro Modifiers ........................................................ 19-4
Macro String Substitution .............................................. 19-4
Macros with Special Handling ........................................... 19-4
Special Target Names ................................................... 19-5
Sample Default Macros, Suffixes, and Rules ............................. 19-5

Section 20--Program Debugging .......................................... 20-1
The Sdb Debugger ....................................................... 20-2
Command Specifiers ..................................................... 20-2
Commands ............................................................... 20-3
The Dbx Debugger ....................................................... 20-5
Alphabetical Summary of Commands ....................................... 20-5

Section 21--ASCII Character Set ........................................ 21-1

Section 22--Command Index .............................................. 22-1

Back Top