Old 22nd June 2017, 18:23   #1
dothebart
Junior Member
 
Join Date: May 2017
Posts: 6
ReadINIFileKeys not working depending on folder

I'm trying to use the ini file modifier over here:

https://github.com/arangodb/arangodb...mplate.in#L903

Its reliably writing 'etc\arangodb3\newValues.ini' and editing the 'arangod.conf' ini file when I install in the default directory, i.e.

c:\Program Files\ArangoDB3 3.2.devel\

The file 'etc\arangodb3\arangod.conf' is altered, "directory" overwritten.

However, if I run the silent mode, and specify different directories for the installation:

c:\c\PROG\

'etc\arangodb3\newValues.ini' is created and contains the new values, however, 'etc\arangodb3\arangod.conf' isn't altered. Since the variables contain the full path of the ini files (as I revalidated with a popup) I've got no clue what could be going wrong here.
dothebart is offline   Reply With Quote
Old 22nd June 2017, 18:38   #2
Anders
Moderator
 
Anders's Avatar
 
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 4,605
And ReadINIFileKeys is? Something from the wiki? I assume you cannot use the normal NSIS ini functions?

The source you linked to is over 1300 lines, please create a Minimal, Complete, and Verifiable example.

IntOp $PostCount $PostCount + 1
Anders is offline   Reply With Quote
Old 23rd June 2017, 09:47   #3
dothebart
Junior Member
 
Join Date: May 2017
Posts: 6
Smile

Sorry, Yes. Its this script:

http://nsis.sourceforge.net/Update_a...dated_INI_file

and I found out what was wrong.
Its checking the error state and aborts, which may eventually be set by preconditions in the script run.

I've fixed the wiki snippet and my situation by adding `ClearErrors`.

will the debug log enabled NSIS write whenever the error flag is set?
dothebart is offline   Reply With Quote
Old 23rd June 2017, 13:40   #4
Anders
Moderator
 
Anders's Avatar
 
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 4,605
No the logging build does not write flag changes for some reason. I will change it so it logs flag changes set by script instructions in the next release.

IntOp $PostCount $PostCount + 1
Anders 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