- 递归修改文件后缀名
find ./ -name "*.c" | awk -F "." '{print $2}' | xargs -i -t mv ./{}.c ./{}.cpp
- 判断进程是否已启动
ps -ef | grep 进程名 | grep -v grep
if [ $? -ne 0 ];then
echo "not runing"
else
echo "runing"
fi
- 文件拷贝显示进度
rsync -avh --progress source_file destination_directory/