无法理解命令查找的语法 [英] Unable to understand the syntax of the command find
本文介绍了无法理解命令查找的语法的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
为什么在下面的命令末尾会出现空的大括号和反向的闪烁?
find * -perm 777 -exec chmod 770 {} \;
我找到大括号的原因之一,但不是反向闪存。
大括号显然是路径
与-exec相同,不同之处在于``{}''被
替换为每个
实用程序的
可能的路径名称
<解决方案
解决方案
解决方案
我建议您改为
找 。 -perm 777 -print0 | xargs -0 chmod 770
xargs表示将查找的结果一段时间到下面的命令。
The find command seems to differ from other Unix commands.
Why is there the empty curly brackets and a backward flash at the end of the following command?
find * -perm 777 -exec chmod 770 {} \;
I found one reason for the curly brackets but not for the backward flash.
The curly brackets are apparently for the path
Same as -exec, except that ``{}'' is replaced with as many pathnames as possible for each invocation of utility
解决方案
I'd recommend that you instead do that as
find . -perm 777 -print0 | xargs -0 chmod 770
"xargs" says to take the results of the find and feed it 20 at a time to the following command.
这篇关于无法理解命令查找的语法的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!