|
Boost Users : |
Subject: Re: [Boost-users] [program_options] Getting access to the remaining argv
From: Francois Mauger (mauger_at_[hidden])
Date: 2009-03-10 09:34:13
Hi
Just a comment, no help sorry!
Some programs behave with command lines argument organized like:
shell> A -a -b -c -- -x -y -z
where -a -b and -c are options for A
and (after the --) -x -y -z are for B.
Unfortunately, I don't know if such mechanism is implemented
within program_options. If so, this is what you want and I'm
interested too!
regards
frc
-- >>> Ruediger Berlich a écrit : > Hi there, > > I have a program ("A") that calls other, external programs ("B"). A can get > a number of command line options, which are parsed with the help of the > program_options library. B may also accept options (which are possibly > defined by other people and not known to me in advance). Thus I want to > pass all those options that are not known to A on to B, in the hope that > they are needed for that program. > > Is there a way to retrieve the remaining argv string, with all > options "known" to A removed ? Or should I better invent a flag of the > following kind for A > > --external-options="-a 1 -b 2 -c 3" > > whose value is passed on to the external program ? > > Thanks and Best Regards, > Ruediger > > > _______________________________________________ > Boost-users mailing list > Boost-users_at_[hidden] > http://lists.boost.org/mailman/listinfo.cgi/boost-users > -- François Mauger Département de Physique - Université de Caen Basse-Normandie courriel/e-mail: mauger_at_[hidden] tél./phone: 02 31 45 25 12 / (+33) 2 31 45 25 12 fax: 02 31 45 25 49 / (+33) 2 31 45 25 49 Adresse/address: Laboratoire de Physique Corpusculaire de Caen (UMR 6534) ENSICAEN 6, Boulevard du Marechal Juin 14050 CAEN Cedex FRANCE
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net