sed/cat/ps
2020-07-29 本文已影响0人
Marksirl
快速删除文件注释和换行:cat file | grep -v "^$" | grep -v "#" > new file
快速替换文件内容:sed "s/tmp/data/g" file > new file
快速关闭进程:ps -ef | grep php-fpm | awk '{print $2}' | xargs sudo kill
快速删除文件注释和换行:cat file | grep -v "^$" | grep -v "#" > new file
快速替换文件内容:sed "s/tmp/data/g" file > new file
快速关闭进程:ps -ef | grep php-fpm | awk '{print $2}' | xargs sudo kill