gnucash master: Rework command line option parsing to store values directly in class member variables

Geert Janssens gjanssens at code.gnucash.org
Fri Jun 5 12:16:32 EDT 2020


Updated	 via  https://github.com/Gnucash/gnucash/commit/422dca54 (commit)
	from  https://github.com/Gnucash/gnucash/commit/d14e2cce (commit)



commit 422dca54e1580744eeb29b9583844ffa9414a1f7
Author: Geert Janssens <geert at kobaltwit.be>
Date:   Fri Jun 5 18:16:25 2020 +0200

    Rework command line option parsing to store values directly in class member variables
    
    The program options libary has a convenience binding for boost::optional
    to indicate whether an option is set or not.
    Use this to store options passed on the command line directly
    in variables for later use. This avoids the need to refer to options
    in several locations using a fixed string (like 'help', 'help-gtk', 'nofile',...)
    
    In addition drop a number of obsolete class member variables.
    They were leftovers from the conversion to c++ and no longer used.



Summary of changes:
 gnucash/gnucash-cli.cpp      | 49 +++++++++++++++---------------------
 gnucash/gnucash-commands.cpp | 22 ++++++++--------
 gnucash/gnucash-commands.hpp | 13 ++++++----
 gnucash/gnucash-core-app.cpp | 60 +++++++++++++++++---------------------------
 gnucash/gnucash-core-app.hpp | 24 ++++++++----------
 gnucash/gnucash.cpp          | 32 ++++++++++++-----------
 6 files changed, 90 insertions(+), 110 deletions(-)



More information about the gnucash-patches mailing list