用于多存档解压缩的 bash 函数/别名
我正在尝试编写一个简单的 bash 别名/函数(以我最快的速度运行)来解开多个 rar 档案。但我的尝试都没有成功。
在 shell 中调用的普通命令也不起作用,我猜这可能是问题的要点:
find . \( -name *.rar -and -not -name *.part*.rar \) -or -name *.part01.rar -exec unrar x {} \;
命令的 find 部分似乎工作正常,尽管 -exec 似乎根本没有被调用。
谢谢!
I'm trying to write a simple bash alias/function (whichever I get working the quickest), that unrars multi-rar archives. None of my attempts work though.
The plain command invoked in the shell doesn't work either, which I guess is probably the gist of the problem:
find . \( -name *.rar -and -not -name *.part*.rar \) -or -name *.part01.rar -exec unrar x {} \;
The find part of the command seems to do its work fine, although the -exec doesn't seem to be invoked at all.
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
unrar 是否可以单独工作(我没有使用过 unrar)?尝试使用 xargs..
Does the unrar work individually (I haven't used unrar)? Try using xargs..