1. How to copy or move all files in a directory except one to another directory?
There is a A and a B directory, a, b, c, d, e and f files in A. We want move a-e to B. How can we do?
I find answers in: http://stackoverflow.com/questions/670460/move-all-files-except-one
Add following sentence in to your .bashrc:
shopt -s extglob
Then, change directory to A, run below command:
mv !(f) B
本文介绍如何使用bash命令批量移动目录中的所有文件,除了指定的一个文件外。通过简单的配置和命令,可以轻松实现文件管理任务。
4万+

被折叠的 条评论
为什么被折叠?



