Archive: wildcard file copy possible?


wildcard file copy possible?
Hi,

I am currently working on a project with which I have to distribute some mpg's. Now I want to do the following:
In my MPG folder are say 10 mpgs, I don't want these to be included in the installer because of dramatic installer size increase but I want to distribute them next to my installer like this:


CreateDirectory $INSTDIR\Mpg
CopyFiles /SILENT Mpg\GEC_110100.mpg $INSTDIR\Mpg\GEC_110100.mpg 127116
CopyFiles /SILENT Mpg\GEC_110200.mpg $INSTDIR\Mpg\GEC_110200.mpg 93648

but I want this to be done in one rule so this installer doesn't have to be edited every time the contents of the MPG folder are different. So I thought, do it like this:

CreateDirectory $INSTDIR\Mpg
CopyFiles /SILENT Mpg*.* $INSTDIR\Mpg\*.*

But this syntax doesn't work. Does anyone know how to accomplish this?

thnx

Tom van Gemert


What about CopyFiles /SILENT Mpg*.* $INSTDIR\Mpg (i.e. forget the last *.*) ?

If that doesn't work you can use FindFirst, FindNext and FindClose to find the files matching the wildcard and issue a copy instruction for each file.


CopyFiles /SILENT $EXEDIR\Mpg\*.* $INSTDIR\Mpg


Thank you very much!
It was just the syntax!

Sunjammer: thanks for pointing me to those Find functions i'll need dem later!