1 #!/bin/
bash
2 if [ -d
"/tmp" ];
then
3 echo "/tmp is exists"
4 else
5 mkdir /
tmp
6 fi
7 if [ -f
"/tmp/size.log" ];
then
8 echo "size.log is exist";
cat /tmp/
size.log
9 else
10 touch /tmp/size.log;
date > /tmp/size.log;
echo "date has been successfully written to size.log"
11 fi
转载于:https://www.cnblogs.com/fanren224/p/8460748.html
转载请注明原文地址: https://mac.8miu.com/read-11510.html