Skip to content
⌘ NSIS Forum Archive

Lots of files, quicker way of listing them?

3 posts

]SK[#

Lots of files, quicker way of listing them?

I want to make an .exe installer for a map pack (for a game). The only problem there's almost 3,000 files. I know I have to list them all in my script but this will take absolutely forever. Is there an easier way around this?

Sorry, I am an NSIS n00b.
Yathosho#
you can place them in a subdir and use the File command with /r swith

File /r "mydir\*.*"
or
File /r "mydir\*.bla"
]SK[#edited
So please tell me if I am wrong here...

SetOutPath "$INSTDIR"
File "tfc\gfx\env\*.*"

SetOutPath "$INSTDIR\models\"
File /r "tfc\models\*.*"
or could I just do...

SetOutPath "$INSTDIR"
File /r "tfc\*.*"
If the /r switch is recursive like I think it is it, then surly the last example I put will work?

*Edit*

Forget it, it works a treat. Thanks man!