Is it possible for me to have an <appSettings />
section in my app.config which contains a number of settings, but which also references an <appSettings />
section in a different file?
This would allow me to keep config options that only the developer should be interested in, e.g. options to show debug output on the main window (very messy but useful to me) or to save certain files to specific locations.
Specifically, this is what I'm trying to achieve:
<!-- this is the appSettings section of the normal app.config file,
which also contains everything else that app.config would -->
<appSettings configSource="AppSettings.config"> <!-- references another file -->
<add key="deployment_config_option1" value="1"/>
<add key="deployment_config_option2" value="2"/>
</appSettings>
<!-- this a new appSettings section of another file called DevSettings.Config
which only contains settings us developers are interested in
by keeping these settings in a different file,
I can ensure it's never deployed -->
<appSettings> <!-- references another file -->
<add key="show_debug_on_screen" value="true"/>
<add key="save_copy_to_desktop" value="false"/>
</appSettings>