doc: missing $_ mention

This commit is contained in:
Kay Marquardt (Gnadelwartz) 2021-01-07 09:00:48 +01:00
parent d3253fdf76
commit 04e3c18cc4
1 changed files with 3 additions and 2 deletions

View File

@ -263,8 +263,9 @@ VAR="$(( 1 + 2 ))" -> (( var=1+2 ))
INDEX="$(( ${INDEX} + 1 ))" -> (( INDEX++ ))
```
The special variable stores the expanded __last__ argument of the previous command.
This allows some useful optimisations, especially in combination with the no-op command `:`.
The special variable `$_` stores the expanded __last__ argument of the previous command.
This allows some nice optimisations, especially in combination with the no-op command `:`,
but be aware of the pitfalls.
```bash
# mkdir plus cd to it