This question already has an answer here:
这个问题在这里已有答案:
- How to set a variable to the output of a command in Bash? 13 answers
如何在Bash中将变量设置为命令的输出? 13个答案
I need to save an output of a command in a variable and then to use it. Currently.
我需要在变量中保存命令的输出然后使用它。目前。
newExtend= $(awk 'NR=='$cont $directy)
echo $newExtend
1 个解决方案
#1
-2
Try:
newExtend = `awk 'NR==' $count $directory`
Those are backticks.
这些都是反击。
#1
-2
Try:
newExtend = `awk 'NR==' $count $directory`
Those are backticks.
这些都是反击。