include only 1 file from excluded directory in sync

Advertisement

pegasus711
Joined:
Posts:
2

include only 1 file from excluded directory in sync

Hello
what I have looks like this
\dirA, <-- include
\dirB, <-- include
\dirC, <-- include
\dirD, <-- include
\dirE, <-- exclude
\_out, <-- exclude
\.git, <-- exclude
.gitignore <-- exclude
.project <-- exclude
.sln <-- exclude
and a bunch of hidden files that I want to exlude

however I want to include only 1 file inside dirD which is Config.json aka dirD\Config.json

I've used the GUI to configure this which looks like this:
dirD/Config.json | *.tgz; *.swo; *.swp; *.7z; *.*~; *.sln; *.bat; *.vcxproj; *.dll; *.git*; .cproject; .project; .git/; .build/; .svn/; _out/; .rmk/; dirD/; .gitignore

what it is now doing is it is also excluding directories that I want to include like directories A,B,C etc (while only checking on dirD/Config.json). When I leave my include section blank and fill up only the exclude sections, it works but then it excludes the entire dirD. Is there a way to tell WinSCP that I want to only include Config.json from dirD while keeping everything else the same?

UPDATE 1:
I've tried this but it doesn't seem to work as well:
dirD/Config.json; */ | *.tgz; *.swo; *.swp; *.7z; *.*~; *.sln; *.bat; *.vcxproj; *.dll; *.git*; .cproject; .project; .git/; .build/; .svn/; _out/; .rmk/; dirD/

Reply with quote

Advertisement

pegasus711

But that means I will have to be very explicit with my include mask right? Which means I will require to include all upper level directories at the very least (I want to include the subdirectories) and the files as well.

So given the directory tree like I have, how will it look?

Reply with quote

Advertisement

You can post new topics in this forum