Inno Setup: pack folder with all subfolders

Prog1020 picture Prog1020 · Dec 26, 2013 · Viewed 31.7k times · Source

I have this line in .iss file:

Source: "..\Tcl\*"; DestDir: "{app}\Tcl"; Flags: ignoreversion

which packs folder Tcl. But it takes only files inside folder, but does not take subfolders inside Tcl. Is there a way to take entire folder Tcl with all subfolders and files? (without listing all that subfolders line by line).

Inno Setup 5.4.2.

Answer

TLama picture TLama · Dec 26, 2013

Yes, there is. Simply include the recursesubdirs flag to your [Files] section entry. The help says about this flag the following:

Instructs the compiler or Setup to also search for the Source filename/wildcard in subdirectories under the Source directory.

So, all you should do is modify your [Files] section entry this way:

[Files]
Source: "..\Tcl\*"; DestDir: "{app}\Tcl"; Flags: ignoreversion recursesubdirs