Shell几个set常用的用法.docxVIP

  • 31
  • 0
  • 约6.14千字
  • 约 6页
  • 2020-10-31 发布于天津
  • 举报
Shell几个set常用的用法 -e如果命令带非零值返回,立即退出 廷里.找分出J 一个程武观则米产王L.d」又胃: %, d: %, c 酉set ~e; rm -f $@: \、 $(CC) -M J (CPPFLAGS) $ $?$$$$; \ sed +sf\(J*\)VoE :]*o 翎.$$$$ $?; \ rm -f $$$$ //测试 2 set -e set hello world -- 置站争行参数 echo lr llhere is exit 5 sed 5,如s(a 7 echo 22here is exit SCONFIG HEADERS-1 没有-e就执行完整个,有就不执行完 +e关闭如果命令带非零值返回,立即退出 # as tn exit STATUS # —二二 # Exit the shell with STATUS, even in a trap ep or £2! context. as_fn exit () { set +e as fn set status si exit JI - 176 } # as fn exit ITT 测试 I 13 set -e 14 set hello world --嶂置命令行参数 15 echo 11tere is exit 5伊 I 16 set +e I 17 哭 d | 18 echo 22

文档评论(0)

1亿VIP精品文档

相关文档