I am using getopt to analyze the inputs for the CLI written in C ++. I have long and short options, and the struct long_options [] element looks like this:
{"verbose", no_argument, NULL, "v"}
One observation is on the command line, even if I go through
he still takes this and directs a function that handles the detailed behavior. Is there a way to make getopt do a strict option check? It should not accept --verb as -verbose right?
source
share