Skip to content
This repository has been archived by the owner on Dec 8, 2017. It is now read-only.

Installer cannot run silent/automated #3

Open
cbielow opened this issue Feb 11, 2016 · 4 comments
Open

Installer cannot run silent/automated #3

cbielow opened this issue Feb 11, 2016 · 4 comments

Comments

@cbielow
Copy link
Contributor

cbielow commented Feb 11, 2016

The installer will show messageboxes (mostly for Proteowizward's .Net depedencies), which currently prevent a silent install.
We would need to add an /SD switch to each MB with a default answer (see http://nsis.sourceforge.net/Docs/Chapter4.html#silent)

Alternatively, the install mode '2' currently excludes ThirdParty installation, i.e. would also be silent out of the box. But we do not specify installation types, see http://nsis.sourceforge.net/Reference/SectionIn, (nor do I know how they can be specified from a commandline).

@jpfeuffer
Copy link
Contributor

We currently have this problem also for the installation of OpenMS for our Usertutorials. Maybe I can have a look at this.
Do you have any updates?

@cbielow
Copy link
Contributor Author

cbielow commented Sep 2, 2016

after browsing the NSIS docs a little, this should be possible via
SetSectionFlags
http://nsis.sourceforge.net/Docs/Chapter4.html#sectionsetflags

@cbielow
Copy link
Contributor Author

cbielow commented Sep 2, 2016

If it is 'silent' or 'silentlog', all sections that have the SF_SELECTED(==1) flag are installed quietly (you can set this flag using SectionSetFlags), and IfSilent (http://nsis.sourceforge.net/Docs/Chapter4.html#ifsilent)

along the lines of (untested)

Section test test_section_id
SectionEnd

Function .onInit
  IfSilent 0 notSilentMark
  # set section 'test' as selected (bit 1 = on)
  SectionSetFlags ${test_section_id} 1
  SectionSetFlags ${anothersection_id} 1
  ...

notSilentMark:
   ... (go on with normal stuff)
FunctionEnd

@jpfeuffer
Copy link
Contributor

Ok I am working on it.
Two problems:

  • Which targets should we install by default when using silent mode? Maybe we can add an NSIS command line option for the configuration type (Full, Recommended, Minimal)?
  • It seems like an installer can not be fully silent when it uses UAC for elevation of rights. Can we fallback to a user-only installation when you do not have admin rights (e.g. install to local users folder and use HKCU registry)?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants