Skip to content

Glossary: Command Line for IT: Bash and PowerShell

$( )

Also written: command substitution

In bash, $( ) runs the command inside it and puts that command's output in its place. For example, kb=$(df --output=avail / | tail -n 1) saves the free space on / in the variable kb.

Where the book teaches it

Related terms

$(( ))bashvariable