Skip to content

Glossary: Linux for Developers

Script arguments ($1, $#, "$@")

Also written: $#, $@, "$@", $1, $0

Inside a script, `$1`, `$2` are its arguments, `$#` is how many there are, `"$@"` is all of them (each kept whole, even with spaces) and `$0` is the script's own name.

Where the book teaches it

Related terms

for loopexit code