We have a site that uses XSLT. There is a config.xslt file that declares a few global variables and it's included in a bunch of other stylesheets. The issue is that we host the site in a few different places and we tweak some of these variables depending on the environment.
Usually, we would create both a main config file and a local config file to keep the local changes out of version control. The local config file can override any of the variables that it needs to without modifying the main config file. However, it is my understanding that this would not be possible within XSLT since XSLT variables can only be declared once and you can't check if they've been declared already.
My question then is: Is it possible to implement such a thing in XSLT?
If not, what would be a better way of managing our configuration?
Edit: Thanks to Martin Honnen for suggesting xsl:import. I've looked up how to use import and it does what I want. However, it leaves me with another issue where the local config file must always exist or else the whole application breaks. Since I want to remove the local config file from version control it's not completely ideal. I found this answer but it's for xslt-2.0 and I'm unfortunately stuck with xslt-1.0.