Treffer: Special Variables I: the Basics.
Title:
Special Variables I: the Basics.
Authors:
Source:
Linux Journal. Jan2009, Issue 177, p26-27. 2p. 1 Color Photograph.
Subject Terms:
Database:
Business Source Premier
Weitere Informationen
The article discusses examples of basic shell variable notations and their usage. It mentions that the use of special variables in the shell can be quite helpful because it can add multiple commands to the Linux shell with a single shared script base. Moreover, it presents scripts using the $# variable such as when one wants to know the number of or obtain positional parameters. It also notes the status variable $? which is used for returning values of a recently executed command. A code snippet for using such status variable when creating and testing a subdirectory is offered. Special variables including $$, $!, and $@ are meanwhile used for temporary file name creation and working with subshells.