条件测试 test检查文件状态 [root@localhost test]# test -e demo11.sh && echo true true [root@localhost test]# test 1 -eq 2 || echo false false [root@localhost test]# [ $USESR='root' ] && echo $USER root