Re: [Flightgear-devel] trying to confirm

2002-11-27 Thread David Megginson
The Tone'ster writes:

 > I got the sense that "--config" was for pointing at a file
 > containing other "--" options ... not for pointing at a different
 > XML config file.

The --config option points to an XML file that will be loaded after
preferences.xml.  So, if you try

  fgfs --config=$HOME/mypref.xml

FlightGear will load $FG_ROOT/preferences.xml first, then
$HOME/mypref.xml.


All the best,


David

-- 
David Megginson, [EMAIL PROTECTED], http://www.megginson.com/

___
Flightgear-devel mailing list
[EMAIL PROTECTED]
http://mail.flightgear.org/mailman/listinfo/flightgear-devel



Re: [Flightgear-devel] trying to confirm

2002-11-26 Thread David Megginson
Curtis L. Olson writes:

 > I haven't looked closely at the code that loads preferences.xml, but
 > if David M. confirms this is hardwired, then definitely, I think the
 > ability to specify an alternate config file would be a very good thing
 > to add.

You can always override parts of it, but for now, preferences.xml is
always loaded first.


All the best,


David

-- 
David Megginson, [EMAIL PROTECTED], http://www.megginson.com/

___
Flightgear-devel mailing list
[EMAIL PROTECTED]
http://mail.flightgear.org/mailman/listinfo/flightgear-devel



Re: [Flightgear-devel] trying to confirm

2002-11-26 Thread The Tone'ster

mmm ...

I got the sense that "--config" was for pointing at a file containing other
"--" options ... not for pointing at a different XML config file.

I haven't tried to confirm this.

Too lazy I guess.

Not a huge deal ...

I'm just trying to figure out if I can hardwire certain assumptions in my code
for the time being to make some issues simpler.

Tony

--- Norman Vine <[EMAIL PROTECTED]> wrote:
> Curtis L. Olson writes:
> > 
> > I haven't looked closely at the code that loads preferences.xml, but
> > if David M. confirms this is hardwired, then definitely, I think the
> > ability to specify an alternate config file would be a very good thing
> > to add.
> 
> From options.cxx
> 
> } else if ( arg.find( "--config=" ) == 0 ) {
> string file = arg.substr(9);
>  try {
>readProperties(file, globals->get_props());
>  } catch (const sg_exception &e) {
>string message = "Error loading config file: ";
>message += e.getFormattedMessage();
>SG_LOG(SG_INPUT, SG_ALERT, message);
>exit(2);
>  }
> 
> norman

=


___
Flightgear-devel mailing list
[EMAIL PROTECTED]
http://mail.flightgear.org/mailman/listinfo/flightgear-devel



Re: [Flightgear-devel] trying to confirm

2002-11-26 Thread Norman Vine
Curtis L. Olson writes:
> 
> I haven't looked closely at the code that loads preferences.xml, but
> if David M. confirms this is hardwired, then definitely, I think the
> ability to specify an alternate config file would be a very good thing
> to add.

>From options.cxx

} else if ( arg.find( "--config=" ) == 0 ) {
string file = arg.substr(9);
 try {
   readProperties(file, globals->get_props());
 } catch (const sg_exception &e) {
   string message = "Error loading config file: ";
   message += e.getFormattedMessage();
   SG_LOG(SG_INPUT, SG_ALERT, message);
   exit(2);
 }

norman

___
Flightgear-devel mailing list
[EMAIL PROTECTED]
http://mail.flightgear.org/mailman/listinfo/flightgear-devel



Re: [Flightgear-devel] trying to confirm

2002-11-26 Thread Curtis L. Olson
Tony,

I haven't looked closely at the code that loads preferences.xml, but
if David M. confirms this is hardwired, then definitely, I think the
ability to specify an alternate config file would be a very good thing
to add.

Regards,

Curt.

The Tone'ster writes:
> 
> all,
> 
> i am trying to confirm my brief investigation.
> 
> it appears to me, by looking at  output that there is no
> mechanism for providing the main binary with an argument pointing at some other
> rendition of "preferences.xml" ?
> 
> Is this correct ? (I hope so ...)
> 
> This would simplify the configuration permutations I have to worry about up
> front for a project I am working on.
> 
> Cheers,
> Tony
> 
> 
> =
> 
> 
> ___
> Flightgear-devel mailing list
> [EMAIL PROTECTED]
> http://mail.flightgear.org/mailman/listinfo/flightgear-devel

-- 
Curtis Olson   IVLab / HumanFIRST Program   FlightGear Project
Twin Cities[EMAIL PROTECTED]  [EMAIL PROTECTED]
Minnesota  http://www.menet.umn.edu/~curt   http://www.flightgear.org

___
Flightgear-devel mailing list
[EMAIL PROTECTED]
http://mail.flightgear.org/mailman/listinfo/flightgear-devel