如何在不覆盖的情况下将2个文件夹与所有子文件夹同步(How to sync 2 folders with all subfolders without overwriting)

[db:摘要]

如何在不覆盖的情况下将2个文件夹与所有子文件夹同步(How to sync 2 folders with all subfolders without overwriting)

我在linux(Ubuntu 12.04)。 我有2个文件夹,文件夹A和文件夹B.(两者都有相同的子文件夹)。 我想复制文件夹B(和所有子文件夹)中不在文件夹A中的所有文件,并使用单个终端命令将它们粘贴到适当的子文件夹中的文件夹A中。 没有覆盖。

谢谢!

I'm in linux (Ubuntu 12.04). I have 2 folders, folder A and folder B. (both have the same subfolders). I would like to copy all files from folder B (and from all subfolders) which are not in folder A and paste them in folder A in the appropiate subfolder, using a single terminal command. Without overwriting.

Thanks!

最满意答案

这应该是诀窍:

cp -r -n ./B/* ./A

This should do the trick:

cp -r -n ./B/* ./A

发布者:admin,转转请注明出处:http://www.yc00.com/web/1691028693a490288.html

相关推荐

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信