Add bash $_ last argument of the previous command
This commit is contained in:
parent
b5cd93a09f
commit
d0da7addd5
13
bash.md
13
bash.md
|
@ -327,12 +327,13 @@ fi
|
||||||
|
|
||||||
### Arguments
|
### Arguments
|
||||||
|
|
||||||
| Expression | Description |
|
| Expression | Description |
|
||||||
| --- | --- |
|
| --- | --- |
|
||||||
| `$#` | Number of arguments |
|
| `$#` | Number of arguments |
|
||||||
| `$*` | All arguments |
|
| `$*` | All arguments |
|
||||||
| `$@` | All arguments, starting from first |
|
| `$@` | All arguments, starting from first |
|
||||||
| `$1` | First argument |
|
| `$1` | First argument |
|
||||||
|
| `$_` | Last argument of the previous command |
|
||||||
|
|
||||||
See [Special parameters](http://wiki.bash-hackers.org/syntax/shellvars#special_parameters_and_shell_variables).
|
See [Special parameters](http://wiki.bash-hackers.org/syntax/shellvars#special_parameters_and_shell_variables).
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue