shell判断文件是否为空

[[ `cat a.log |wc -l` -eq 0 ]] && echo "file is empty"

posted @ 2017-03-29 19:26  Agoly  阅读(6679)  评论(0编辑  收藏  举报