Old 24th January 2011, 11:40   #1
Tallmaris
Junior Member
 
Join Date: Jan 2011
Posts: 10
Question Extract only selected Files from the installer

HI All,

As far as I know the "File" command will not only put the file I want into the final Installer, but also, when running, it will extract the file to the Output Path specified.

Do you know if there is a way to separate the two tasks? What i would like to do is to pack for example 6 exe files, one per installer language, into the installer, but when installing I basically only need to extract the one I need based on the OS language.

I tried ReserveFiles but I reckon this is used for other things and you cannot pick which of the reserved files to extract.

Thanks!
Tallmaris is offline   Reply With Quote
Old 24th January 2011, 12:56   #2
Afrow UK
Moderator
 
Afrow UK's Avatar
 
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
http://forums.winamp.com/showpost.ph...58&postcount=9

Stu
Afrow UK is offline   Reply With Quote
Old 24th January 2011, 13:20   #3
Tallmaris
Junior Member
 
Join Date: Jan 2011
Posts: 10
Yes, that is a solution, but since all the files have basically the same name except for the final 3 letters, I was looking to use something like this:

code:
File /r "myfile*.*"


At the top and then pick up just what I need... mostly because I need 2 checks, one for the language and one for the 64 bit. The main idea would be to put all the files into the installer and then do a check for the language and fill one var ($R0 for example), then check the 32 bit and fill another var ($R1) and then call for example:

code:
ExecWait "myfile$R0_$R1.exe"


If that is not possible then of course the only option would be to duplicate all checks... that's fine (in a way) :/
Tallmaris is offline   Reply With Quote
Old 24th January 2011, 17:37   #4
Afrow UK
Moderator
 
Afrow UK's Avatar
 
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
I don't see what the problem is. Use the ${Switch} statement. If you don't want to have to repeat the file name then you can use a define or a macro.

Stu
Afrow UK is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump