关注

(5)
in shell command, `true` will always have a 0 error code and `false` will always have a 1 error code.

(6)
`false && echo "Oops fail"`, the second part won't be executed.

Using a semicolon `;` in the middle is a way to concatenate 2 commands.

(7)
to use the output of a command:
`$(command)`
example: `echo "we are in $(pwd)"`

(8)
$0 the name of the script
$# the number of arguments
$$ the process ID of the script
$@ all the arguments

登录以加入对话
雾海

雾海是一个开放且不限制讨论主题的非营利性中文社区,名字来源于德国浪漫主义画家 Friedrich 的画作《雾海上的旅人》。生活总是在雾海中吞吐不定,不管怎么艰辛,他还是站在了这里!希望大家在这里玩的开心~