Help about multiple options.

Hakan Bayındır <[email protected]> Sun, 30 Jan 2022 11:21:13 +0300
Newsgroups gmane.comp.gnu.gengetopt.general
Message-ID <3129982.pANTzkfq9E@orion>
--===============0103146806586245254==
Content-Type: multipart/signed; boundary="nextPart4524648.NjIMD8BAIq"; micalg="pgp-sha512"; protocol="application/pgp-signature"

--nextPart4524648.NjIMD8BAIq
Content-Transfer-Encoding: 7Bit
Content-Type: text/plain; charset="us-ascii"; protected-headers="v1"
From: Hakan =?utf-8?B?QmF5xLFuZMSxcg==?= <[email protected]>
To: [email protected]
Subject: Help about multiple options.
Date: Sun, 30 Jan 2022 11:21:13 +0300
Message-ID: <3129982.pANTzkfq9E@orion>

Hello,

I'm developing an application for some time and its backed by an elaborate 
logging library, which supports multiple levels of verbose output. 

To implement this feature in gengetopt, I've used the following line:

option "verbose" v "Enable verbose output." typestr="level" int default="0" 
optional

This allows me to pass "-v 2" or "--verbose 2" style options to set desired 
verbosity, however I want to be able to pass "-v", "-vv" and similar styled 
flags for verbosity selection. I've dug version 2.23 documentation but failed 
to find/understand if it's possible, and how it's done.

Any help will be greatly appreciated,

Thanks in advance,

Hakan
--nextPart4524648.NjIMD8BAIq
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: This is a digitally signed message part.
Content-Transfer-Encoding: 7Bit

-----BEGIN PGP SIGNATURE-----

iQIzBAABCgAdFiEESB/YR8B39SpOABfYjX8HYnb9o5UFAmH2SnkACgkQjX8HYnb9
o5UV9RAA0pGY2f3pxBZrHl5JFnE6eN173k03Kk4rWoZ1Ms3HhvI7+A9ArZdGqgBS
d44m9XLTZeV1fJZ0rFD3XxEQURM5k98wOLrNtgQOCZrl6e6Xi43WgLAOvPwsPIqw
ByxQ8aKcxbt9utiPxbRdYGhREXSWgiRfC0lG+oVOdyeXKGMamgyma7J/0xE/k+mb
C7gw/Oixp8UY5u4cv3PMMkM6T5No1K9MFDp+wRR86LJ0o93NhsyTzsxsd/i35e5c
n4y1J93UcArgxHB0Xu1Pj71ZhFBJhpCRhJ0VkHnqYC2iMqwQQ4D9Uf0BhkFQ5fj9
79A4yyY/t6WO8FnYjvrpHPm2ucpmJWbj9uK41Z2CMnVskv8WtydXwVcSOeg4osN4
hOobA0Sys4t5DPbkI6eLv6EsWAtBzl8mx38iW3sRLK4vYdw7ymznyBjbQxOmKafd
7zDXyRhWgh/rmD6S0wQ3uPsnngAa8of771fNCfeMBfySdzDdK2+R9oxWb3kvGyZe
s5CL+50BLdWPw9qB4m+fR2pEHuo7I6USInL8l2St2YuU7IOotCvtHgE+GYfWEvh+
QJW6ba3d1SP4f0oG1EWdXeFqxIEVBAwNMx1WG4LlkbPgWYCW68KKieTwwgmqXW+A
DA4qIY+4N1nDQklqlLfISoHCLrEyNYnGQpQAKDSqueHrWGahxYc=
=BsMy
-----END PGP SIGNATURE-----

--nextPart4524648.NjIMD8BAIq--





--===============0103146806586245254==
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: base64
Content-Disposition: inline

X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KSGVscC1nZW5n
ZXRvcHQgbWFpbGluZyBsaXN0CkhlbHAtZ2VuZ2V0b3B0QGdudS5vcmcKaHR0cHM6Ly9saXN0cy5n
bnUub3JnL21haWxtYW4vbGlzdGluZm8vaGVscC1nZW5nZXRvcHQK

--===============0103146806586245254==--