find : find命令详解
Posted moox
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了find : find命令详解相关的知识,希望对你有一定的参考价值。
find : find命令详解
find
解释:find - search for files in a directory hierarchy
用法:Usage: find [-H] [-L] [-P] [-Olevel] [-D help|tree|search|stat|rates|opt|exec] [path...] [expression]
find /server/scripts/ --查找显示 绝对路径文件
[root@zabbix scripts]# find /server/scripts/
/server/scripts/
/server/scripts/test1.sh
/server/scripts/1
/server/scripts/c_args.sh
/server/scripts/c_vars.sh
/server/scripts/c_read.sh
/server/scripts/aa
/server/scripts/lamp.sh
/server/scripts/menu.sh
/server/scripts/judge_system_mem.sh
/server/scripts/check_web.sh
/server/scripts/com_if.sh
find /server/scripts/ |xargs md5sum -- 批量处理文件
要执行时,只需要交给bash就可以:find /server/scripts/ |xargs md5sum|bash
[root@zabbix scripts]# find /server/scripts/ |xargs md5sum
md5sum: /server/scripts/: Is a directory
9d2de0fe1d6a415e87656e0b7aeeabff /server/scripts/test1.sh
d41d8cd98f00b204e9800998ecf8427e /server/scripts/1
738a54bab35dc027e6a8a5d82ef3ba6f /server/scripts/c_args.sh
738a54bab35dc027e6a8a5d82ef3ba6f /server/scripts/c_vars.sh
5f6295bdaa1e2ca989ddedb8f8cdc77d /server/scripts/c_read.sh
597df6cb3d430e5bb276cf18bd2112f1 /server/scripts/aa
9f8af9a257536cb1e41e48df6e98a100 /server/scripts/lamp.sh
eaf58b51850ea72c8ac0a85179a075fd /server/scripts/menu.sh
8462deda79cb774f7b6a43dd320a26b8 /server/scripts/judge_system_mem.sh
ec5552fa6189bad44ecf16e134cf4f42 /server/scripts/check_web.sh
3fc2f7cd9d5f5743a9a967b4fb44a1bb /server/scripts/com_if.sh
find /server/scripts/ -name
[root@zabbix scripts]# find /server/scripts/ -name "test1.sh"
/server/scripts/test1.sh
[root@zabbix scripts]# find /server/scripts/ -name "*t*.sh*"
/server/scripts/test1.sh
/server/scripts/judge_system_mem.sh
find /server/scripts/ -type
参数-type x
文件类型
- -type f --文件
- -type d --目录
- -type s --...
[root@zabbix scripts]# find /server/scripts/ -type d
/server/scripts/
/server/scripts/moox
以上是关于find : find命令详解的主要内容,如果未能解决你的问题,请参考以下文章
mvn命令异常:An error has occurred in Javadoc report generation: Unable to find javadoc command异常已解决(代码片段
mvn命令异常:An error has occurred in Javadoc report generation: Unable to find javadoc command异常已解决(代码片段