[Opensim-dev] Ini file(s) loading
Melanie
melanie at t-data.com
Fri Mar 6 08:55:42 UTC 2009
Hi,
Jeff Ames wrote:
> Melanie wrote:
>> read [the config directory] first
>> then read the inimaster
>> then read the inifile
This is because the config/* files would hold the defaults, they
must be read first.
[...]
>
> Then we could break up and move OpenSim.ini.example entirely to
> config/*.ini.example files, and when the user wants to change a value,
> create foo.ini based on foo.ini.example (copying the whole file if
> they want everything, or only adding the options they want to
> explicitly set).
>
I was suggesting to get away from *.example files. Instead, I am
proposing to break up OpenSim.ini into *.ini files that provide the
defaults. The in-code defaults are a requirement of Nini, but they
are not functional, just ignore that they're there. The requirement
for an OpenSim.ini file in code needs to be dropped, of course.
That is why the config directory needs to be read first - it
provides the defaults! Inimaster would be rendered useless by the
load order you're proposing!
> Then I guees the load order would be:
> - read inimaster (if present)
> - read config/*.ini (if present)
> - use defaults in code for anything not set
>
See above, this won't serve the users' needs. In your scenario, if
the config/*.example changes, they'd still need to merge.
What I propose, to reiterate, is this:
Break up Opensim.ini.example into config/*.ini. Uncomment all the
options so they serve as defaults.
Remove the explicit requirement for an ini file.
This way, sitewide changes from the provided defaults go to
inimaster, and machine/instance settings go to opensim.ini.
The files in config/ can remain unchanged and can be updated on
every svn update, without manual merging.
Of course, many other use cases are possible, including
modifications to config/*.ini if desired, or omitting either
configuration source.
Melanie
More information about the Opensim-dev
mailing list