Skip to content

Commit 7e03914

Browse files
committed
2019-04-21
1 parent 2c318df commit 7e03914

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

markdown-file/Bash.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,7 @@ drwxr-xr-x. 5 root root 4096 3月 26 10:57,其中最前面的 d 表示这是
107107
- `find . -name "lin*" -exec ls -l {} \;`,当前目录搜索lin开头的文件,然后用其搜索后的结果集,再执行ls -l的命令(这个命令可变,其他命令也可以),其中 -exec 和 {} \; 都是固定格式
108108
- `find /opt -type f -size +800M -print0 | xargs -0 du -h | sort -nr`,找出 /opt 目录下大于 800 M 的文件
109109
- `find / -name "*tower*" -exec rm {} \;`,找到文件并删除
110+
- `find / -name "*tower*" -exec mv {} /opt \;`,找到文件并移到 opt 目录
110111
- `find . -name "*" |xargs grep "youmeek"`,递归查找当前文件夹下所有文件内容中包含 youmeek 的文件
111112
- `find . -size 0 | xargs rm -f &`,删除当前目录下文件大小为0的文件
112113
- `du -hm --max-depth=2 | sort -nr | head -12`,找出系统中占用容量最大的前 12 个目录

0 commit comments

Comments
 (0)