On Tue, 2005-12-06 at 15:31 +1300, Steve Wray wrote: > the file generic_environment.cf gets imported *after* aptconf.cf which > means that variables which are set in generic_environment.cf don't make > it into aptconf.cf > > I've had to resort to importing all of my generic*.cf directly in my > cfagent.conf which makes it less maintainable and, well, ugly. > > > Any ideas how to force a set of files to be imported in the right order?
The parser, for better or worse, imports all files at the end of the current file; so what's happening is: * cfagent.conf gets parsed, a list of imports is built * generic.cf gets parsed, and a list of imports is built, including generic_environment.cf, appended to the list * ... * aptconf.cf gets parsed * ... * generic_environment.cf gets parsed Yeah, it's pretty weird, when everything else on the planet handles include files in place. You could work around it by pushing everything after generic.cf into another file, which would then have its imports put after the generic imports. _______________________________________________ Help-cfengine mailing list [email protected] http://lists.gnu.org/mailman/listinfo/help-cfengine
