how to get the output of a command in shell script code example Example: store result of command in variable bash variable=$(command [option…] argument1 arguments2 …)