At 10:43 AM 1/15/2003, Vladimir Prus wrote:
>I don't know how to compare number of people who need command line to the
>number of people who *also* need config file. I suppose that as your
>program grows bigger, you're likely to need config file too. The
transition
>should be simple.
I run into exactly that in production code.
At first, no one mentions the need for a config file.
Then, as more options are added over time, someone requests a config file.
I've got a little function that updates argc and argv to point to a new set
of values containing the original, less the config file indirection arg,
plus the args found in the config file (which are the same format as
regular command line arguments.) Works like a charm; very simple, and
everyone is happy. I usually echo the full set of args to cout as
documentation of the actual args seen by the program.
That's a long way of supporting Vladimir's views above. People first need
just command line arguments, then later realize a config file would be
nice. And yes, the transition should be simple and transparent.
--Beman
_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
- [boost] Preliminary submission: command line & conf... Vladimir Prus
- [boost] Preliminary submission: command line &... Vladimir Prus
- RE: [boost] Preliminary submission: command li... Hartmut Kaiser
- [boost] Re: Preliminary submission: comman... Vladimir Prus
- RE: [boost] Re: Preliminary submission... Hartmut Kaiser
- [boost] Re: Preliminary submission: command line &... Gennadiy Rozental
- Re: [boost] Re: Preliminary submission: comman... Vladimir Prus
- [boost] Re: Re: Preliminary submission: co... Gennadiy Rozental
- [boost] Re: Preliminary submission: co... Vladimir Prus
- [boost] Re: Re: Preliminary submi... Beman Dawes
- [boost] Re: Re: Preliminary s... Gennadiy Rozental
- Re: [boost] Re: Preliminary submi... David A. Greene
- Re: [boost] Re: Preliminary s... Rene Rivera
- [boost] Re: Preliminary submi... Vladimir Prus
- [boost] Re: Preliminary s... Vladimir Prus
- [boost] Formal review request: command line & ... Vladimir Prus
- RE: [boost] Preliminary submission: command line &... Rozental, Gennadiy
- Re: [boost] Preliminary submission: command li... Vladimir Prus
- RE: [boost] Preliminary submission: command line &... Rozental, Gennadiy
- Re: [boost] Preliminary submission: command li... Vladimir Prus