Skip to content

Commit cc2adaa

Browse files
committed
2016-08-23完善bash
1 parent a8a4f59 commit cc2adaa

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Bash.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,8 @@
103103
- `find /opt -type f -iname .oh-my-zsh`,其中 /opt 代表目录名,-type f 代表只找文件,.oh-my-zsh 代表搜索的是隐藏文件名字为 oh-my-zsh 的
104104
- `find /opt -type d -iname .oh-my-zsh`,其中 /opt 代表目录名,-type d 代表只找目录,.oh-my-zsh 代表搜索的是隐藏文件夹名字为 oh-my-zsh 的
105105
- `find . -name "lin*" -execls -l{}\;`,当前目录搜索lin开头的文件,然后用其搜索后的结果集,再执行ls -l的命令(这个命令可变,其他命令也可以),其中 -exec 和 {}\; 都是固定格式
106+
- `find /opt -type f -size +800M -print0 | xargs -0 du -h | sort -nr`,找出 /opt 目录下大于 800 M 的文件
107+
- `du -hm --max-depth=2 | sort -nr | head -12`,找出系统中占用容量最大的前 12 个目录
106108
- `cat /etc/resolv.conf`,查看 DNS 设置
107109
- `netstat -tlunp`,查看当前运行的服务
108110
- ``,

0 commit comments

Comments
 (0)