Solved

Could you point how to correctly script to make nullsoft scriptable installer consider the subfolders?

Posted on 2016-08-26
9
54 Views
Last Modified: 2016-08-27
Hi Experts

I'm using nullsoft scriptable installer.

I need that the instalation consider subfolders accordingly to:

img001
Could you point how to correctly script to make the instalation consider the subfolders?

Thanks in advance.
0
Comment
Question by:Eduardo Fuerte
  • 5
  • 4
9 Comments
 
LVL 51

Expert Comment

by:Joe Winograd, EE MVE
ID: 41772499
The /r parameter on the File command will recurse into all subfolders. So this install section should do it:

section "install"
  SetOutPath $INSTDIR
  File /r Bibliesp
sectionEnd

Open in new window

Regards, Joe
0
 

Author Comment

by:Eduardo Fuerte
ID: 41772928
Hi

I don't know if I did it correctly.

The script used:
  SetOutPath "$INSTDIR"
  File /r "Main Program"
  FileWrite $R0 "Install directory is $INSTDIR. $\r$\n"
...

  InstallDir "C:\Bibliesp\"

Open in new window


The Nullsoft instalation folders:
img001
The error I had:
img002
Any other sugestion?
0
 

Author Comment

by:Eduardo Fuerte
ID: 41772939
Here is the complete script
p3Biblioteca_FULL_v1.nsi
0
 
LVL 51

Expert Comment

by:Joe Winograd, EE MVE
ID: 41772941
It says:

"Main Program" -> no files found.

In the file /r command you should specify the name of the root folder. For example, here's a small, working script that will install "root folder" and all of its subfolders:

InstallDir "$PROGRAMFILES\Test Installing Subfolders"
Name "Test Subfolders"
OutFile "Setup.exe"
section "install"
  SetOutPath $INSTDIR
  file /r "root folder"
sectionEnd

Open in new window

The above installer works — try it. It will create a Setup.exe that installs root folder and all its subfolders (and all files) in $PROGRAMFILES\Test Installing Subfolders (such as c:\Program Files (x86)\Test Installing Subfolders on a 64-bit system). Regards, Joe
0
What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 
LVL 51

Accepted Solution

by:
Joe Winograd, EE MVE earned 500 total points
ID: 41772953
Our messages crossed. I did not study your entire 395-line script, but based on the installation folder structure you just posted, I think that all you need to do is change your file /r command to this:

File /r "c:\A_Instala_Biblioteca_V1"

Open in new window


Of course, in a 395-line script, there could be other issues, but your File /r "Main Program" is clearly the first problem. Regards, Joe
0
 

Author Comment

by:Eduardo Fuerte
ID: 41773081
Hi @Joe

I didn't intend you check all the script file, I attached it just in case any other information eventally had  beeing needed.

Following what you posted, I just made a minor change the instalation folder to:

img003
File /r "c:\A_Instala_Biblioteca_V1\A_Instala_Biblioteca_FULL_V1\Bibliesp"

Open in new window


Install the package and the instalation is:

img004
That attended my needs.
0
 
LVL 51

Expert Comment

by:Joe Winograd, EE MVE
ID: 41773088
> That attended my needs.

That's great news, Eduardo! I'm glad to hear that the problem is resolved. Regards, Joe
0
 

Author Closing Comment

by:Eduardo Fuerte
ID: 41773114
Joe as usual you give a very good help!

Thank you.
0
 
LVL 51

Expert Comment

by:Joe Winograd, EE MVE
ID: 41773118
You're welcome, Eduardo. And thanks to you for the nice compliment — I appreciate hearing it! Regards, Joe
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

This article describes how to use the timestamp of existing data in a database to allow Tableau to calculate the prior work day instead of relying on case statements or if statements to calculate the days of the week.
A list of useful business intelligence software.
Video by: Tony
This video teaches viewers how to export a project from Adobe Premiere Pro and the various file types involved.
This Micro Tutorial will give you basic overview of the control panel section on Windows 7. It will depth in Network and Internet, Hardware and Sound, etc. This will be demonstrated using Windows 7 operating system.

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now