You are here

KompoZer: .nsi script

2 posts / 0 new
Last post
tanisthalon
tanisthalon's picture
Offline
Last seen: 3 years 3 months ago
Developer
Joined: 2006-02-11 08:02
KompoZer: .nsi script

Just looking at the code and just wanted to query line 278 on the KompoZer 0.7.10 Rev 2 script. It reads StrCpy $PROFILEDIRECTORY $TEMP\${NAME}\profile, but shouldn't it read StrCpy $PROFILEDIRECTORY $TEMP\${NAME}\plugins? Yes I know there isn't anything in the defaultdata plugins folder but I just wasn't sure it was correct.

Chris Morgan
Chris Morgan's picture
Offline
Last seen: 8 years 10 months ago
Joined: 2007-04-15 21:08
Yup... a bug.

Yes, this is a bug which is still outstanding. What it means is that when running with local settings, KompoZer will not see any plugins, as when the MOZ_PLUGIN_PATH environment variable is set (in line 434), it will go to the wrong path. No files are left behind though, as line 453 recursively eradicates the folder $TEMP\${NAME}.
As an aside, I spotted this bug while using this launcher to make BPBible Portable... but, God willing, you'll hear more about that later today.

I don't think it's worth Rev 3, though.
Official bug report for KompoZer Portable 0.7.10 Rev 2
In Other\Source\KompoZerPortable.nsi, line 278 (made bold):

	SkipSplashScreen:
		;=== Run locally if needed (aka Live)
		StrCmp $RUNLOCALLY "true" "" CompareProfilePath
		RMDir /r "$TEMP\${NAME}\"
		CreateDirectory $TEMP\${NAME}\profile
		CreateDirectory $TEMP\${NAME}\plugins
		CreateDirectory $TEMP\${NAME}\program
		CopyFiles /SILENT $PROFILEDIRECTORY\*.* $TEMP\${NAME}\profile
		StrCpy $PROFILEDIRECTORY $TEMP\${NAME}\profile
		CopyFiles /SILENT $PLUGINSDIRECTORY\*.* $TEMP\${NAME}\plugins
		StrCpy $PROFILEDIRECTORY $TEMP\${NAME}\profile
		CopyFiles /SILENT $PROGRAMDIRECTORY\*.* $TEMP\${NAME}\program
		StrCpy $PROGRAMDIRECTORY $TEMP\${NAME}\program
		Push $TEMP\${NAME}
		Call Attrib

needs to be changed to

	SkipSplashScreen:
		;=== Run locally if needed (aka Live)
		StrCmp $RUNLOCALLY "true" "" CompareProfilePath
		RMDir /r "$TEMP\${NAME}\"
		CreateDirectory $TEMP\${NAME}\profile
		CreateDirectory $TEMP\${NAME}\plugins
		CreateDirectory $TEMP\${NAME}\program
		CopyFiles /SILENT $PROFILEDIRECTORY\*.* $TEMP\${NAME}\profile
		StrCpy $PROFILEDIRECTORY $TEMP\${NAME}\profile
		CopyFiles /SILENT $PLUGINSDIRECTORY\*.* $TEMP\${NAME}\plugins
		StrCpy $PLUGINSDIRECTORY $TEMP\${NAME}\plugins
		CopyFiles /SILENT $PROGRAMDIRECTORY\*.* $TEMP\${NAME}\program
		StrCpy $PROGRAMDIRECTORY $TEMP\${NAME}\program
		Push $TEMP\${NAME}
		Call Attrib

I am a Christian and a developer and moderator here.

“A soft answer turns away wrath, but a harsh word stirs up anger.” – Proverbs 15:1

Log in or register to post comments