有人能告诉我是否应该在shell脚本中包含变量的引号?
例如,以下是正确的:
xdg-open $URL [ $? -eq 2 ]
要么
xdg-open "$URL" [ "$?" -eq "2" ]
如果是这样,为什么?
unix linux bash shell quotes
bash ×1
linux ×1
quotes ×1
shell ×1
unix ×1