Ok, if I want to copy all files in the directory tree containing *.log in the filename
I could write something like
XCOPY D:\*.log ...... D:\targetdir
But how do I specify if I want to copy all DIRECTORIES which contain the pattern "log"
to the targetdir ?
XCOPY D:\*log*\*.* ..... D:\targetdir
doesn't work. At least it would help if I could specify that only the LAST part of the path
is "log". In other words that log does not appear inside the path. Thus files in dirs like
D:\project1\part1\log\myfile.txt should be copied at least
D:\project2\logs\part2\myfile2.txt should be copy too only if possible
Is this possible with XCOPY or a "tricky" workaround ?