My thought is that the global settings on Win2000/XP/2003 should bePlease note, that this directory name "Application Data" is hardwired inside the Ethereal code,
available in the "Documents and Settings/All Users/Application Data"
directory, and that user-specific files should reside in the
"Application Data" directory of the user's settings. Please note that
there are Windows-specific variables that are used to find the actual
directory names for the application data and the user profile, but I
don't know those by heart.
so this might lead to different locations for installer and Ethereal, breaking the installation things.
Please note also, that internationalized windows version will name the dir differently, e.g. the german
windows calls this
"Documents and Settings/All Users/Applikationsdaten"
So be *very* sure when changing something here...
I also don't know the NS/IS installer so I don't know if you canAs this is only a different location for files and such, this could be done with some effort.
specify whether you want the application(s) to be instlled for the
installing user or for all users on the computer.
My nsis script that I use to build the Win32 distribution, adds theThere should be some sample files available for *all* platforms, not only win32. A distributor then might overwrite with his own settings,
option to install the preference files at install time. They are then
removed by the install when the program is removed. It is nice to give
new users sample color, display, and capture filters when they install
Ethereal.
as he might have a different set of files in mind.
They can then uncheck the option if they do not want toSupplying new users with sample configuration is a good thing IMHO.
overwrite their existing preference files.
BUT UNDER ANY CIRCUMSTANCES, DON'T OVERWRITE PREVIOUS USER SETTINGS BY DEFAULT!!!
Sorry to be so "loud", but that's really a very important point!
If the user has previous settings, he should have to select something before overwrite things.
In this case it might be also a good idea, to ask him with a dialog box or such, if he's really sure.
It might be a better idea to tell the user at uninstallation start to close all running instances before continuing.A nice thing that could be added is that the Ethereal distribution do much the same thing but I think a check for the existence of the preference files would be nice and then prompt the user if they wanted to overwrite.
I used to provide the preference files and then gave instructions on how to install. But to many time people would call me about problems because they were not logging into the system with the administrator user object. The section of the Ethereal.nsi that installs the preference files reads the APPDATA environment variable to get the path to the users application data directory.
Section "Preference Files" ;-------------------------------------------
ReadEnvStr $R0 "APPDATA" CreateDirectory "$R0\Ethereal" SetOutPath $R0\Ethereal File "\Documents and Settings\Administrator\Application Data\Ethereal\preferences" File "\Documents and Settings\Administrator\Application Data\Ethereal\dfilters" File "\Documents and Settings\Administrator\Application Data\Ethereal\cfilters" File "\Documents and Settings\Administrator\Application Data\Ethereal\colorfilters" SectionEnd
skipped if file doesn't existWould it be good to add : (from bigtest.nsi )
IfFileExists "$INSTDIR" 0 NoErrorMsg
MessageBox MB_OK "Note: $INSTDIR could not be removed!" IDOK 0 ;
NoErrorMsg:
to the script?
Yes. There are probably a lot of things in the installer which can be improved. The new NSIS 2 provides perhaps more useful but still unused features.
I managed to run the unistaller while ethereal was active and gotall the *.dll's and
the directories left.first and then do the check
I don't know if it would be a good idea to try and remove one *.dll
so the 'uninstaller' don't get deleted or if there's another betterway of doing it?
There should be at leaast some sort of error check or a message for the user. I will do some investigation.
The uninstaller don't know which files are currently in use when starting, so a check on a specific file will
probably not do the job completely.
I think NSIS support sections for the uninstaller too. So the user can select, which files to be uninstalled.Should we also ask if the prefs. files should be deleted ?
Is there an easy way in nsis to do that?
This should be default to *not* remove the users pref files for the same reasons described above!
Regards, ULFL
_______________________________________________ Ethereal-dev mailing list [EMAIL PROTECTED] http://www.ethereal.com/mailman/listinfo/ethereal-dev