Skip to content

Instantly share code, notes, and snippets.

@Andyliwr
Last active June 11, 2019 01:24
Show Gist options
  • Save Andyliwr/0ca704f46288db49ea95d0fd35696890 to your computer and use it in GitHub Desktop.
Save Andyliwr/0ca704f46288db49ea95d0fd35696890 to your computer and use it in GitHub Desktop.
Linux中常用命令
# 查找文件并批量重命名
find . -name "*Editor.js" | xargs rm -f
find . -name "index.js" | xargs rm -f
find . -name "index.js" | xargs rm -f
find . -name "*Preview.js" -exec mv {} index.js \;
# 首行添加一段文字
sed -i '1i/* eslint-disable */' aaa.txt
# 杀死所有node进程
ps -ef|grep node|awk '{print $2}'|xargs kill -9
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment