- VAR1=`ls`; echo $VAR1
- VAR2=$(ls); echo $VAR2
- VAR3="$(ls)"; echo $VAR3
- How to set a variable to the output from a command in Bash?
- Problem with backticks in shellscript
- Display output of a Bash command and keeping the output in a variable
- Apply a filter to the value of a variable using backticks
_EOF_
沒有留言:
張貼留言