还有一种方法是使用 command || true ,使得该命令即使执行失败,脚本也不会终止执行。 #!/bin/bash set -e foo || true echo bar. 上面代码中, ...
確定! 回上一頁