find的exec参数

find的-exec参数执行命令时,当前目录是执行者运行find程序时所在的目录。如果需要在执行命令时进入匹配项所在目录,使用-execdir参数。两者均不能识别命令中的通配符,可以通过间接调用一个单行脚本来解决。

This entry was posted in 应用 and tagged , , . Bookmark the permalink.

发表评论

电子邮件地址不会被公开。 必填项已用 * 标注

*

Note: If you are replying to another commenter, click the "Reply to {NAME} ↵" button under their comment!