[英]Move multiple files in same directory without typing directory name each time (Linux)
I have a directory dir with files a, b, c, and I want to move them 我有一个包含文件a,b,c的目录dir,我想移动它们
mv dir/a dir/b dir/c ...
is the standard way to do it. 是这样做的标准方法。 Is there a shortcut to avoid typing dir/ multiple times?
是否有避免多次输入dir /的快捷方式? Perhaps like so:
也许像这样:
mv dir/(a, b, c) ...
是的,它与您的猜测非常相似: mv dir/{a,b,c} dest
Yes, you should be able to do the following 是的,您应该可以执行以下操作
mv dir/{a.out, b.out, c.out} /path/to/newdirectory/
You just need to use curly braces instead of parenthesis. 您只需要使用花括号而不是括号即可。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.