I wanted the same directory structure to be recreated at destination as was found at the source which I don't think currently happens. I took a look at how svgmin does it and managed to create a solution. It does mean you have to set cwd in the config in order to separate it from the source files.
It basically uses this.files instead of this.data.files which already has a reference to the globbed files and gives you the ability to then keep the cwd part separate meaning you can then recreate the full directory path in the destination.
Also, I think this will solve the issue which is being talked about here
I wanted the same directory structure to be recreated at destination as was found at the source which I don't think currently happens. I took a look at how svgmin does it and managed to create a solution. It does mean you have to set
cwd
in the config in order to separate it from the source files.It basically uses
this.files
instead ofthis.data.files
which already has a reference to the globbed files and gives you the ability to then keep thecwd
part separate meaning you can then recreate the full directory path in the destination.Also, I think this will solve the issue which is being talked about here