VAR*_*121 0 bash
我写了一个小的bash程序,需要读取一个带有名字的文件input.我希望脚本打印消息file not found,如果找不到文件则退出或自行终止.
input
file not found
P.P*_*.P. 5
在阅读之前,检查文件是否存在:
if [ ! -f input ]; then echo "File Not found" exit 1 fi
归档时间:
13 年,2 月 前
查看次数:
241 次
最近记录: