Вопрос

I am writing a Beyond Compare script which will sync two folders. Consider these folder structures:

Folder1
-------
SubfolderA
    --FileA(modified)
    --FileB(new)
SubfolderB
    --FileC
FileD(modified)


Folder2
-------
SubfolderA
    --FileA
FileD

Now what I am trying to achieve is that after syncing them, only the files and folders pertaining to Folder2 should be copied to it.

So in this case

-the modified ones and the new ones in the SubfolderA should be copied on its counterpart

-SubfolderB should not becopied or created as there is no such subfolder in Folder2. 

-Whereas the modified FileD should be copied.

What should go along with the select and update or sync

Thanks in advance

Это было полезно?

Решение

So after waiting for some time and not finding an answer I posted the same question to one the developers of the Beyond Compare team. He said its not possible in the current version. But there is a workaround for it.

What we can do is hardcode the values of the folders that we don't need in the filter list and this will take care of it.

So for our example we can make a script like

filter "-SubfolderB\"
load c:\Folder1 c:\Folder2
sync update:left->right
Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top