brbzull0 opened a new issue, #12605: URL: https://github.com/apache/trafficserver/issues/12605
With the change, `ArgParser` will make sure that only one of the arguments in the mutually exclusive group was present on the command line. Right now you can have two command options that should be exclusively and handle them internally by checking one after another, the idea would be to have something like we have in [python](https://docs.python.org/3/library/argparse.html#mutual-exclusion). A clear example of this would be: ``` server_command.add_command("drain", "Drain the requests", [&]() { command->execute(); }) .add_example_usage("traffic_ctl server drain [OPTIONS]") .add_option("--no-new-connection", "-N", "Wait for new connections...") .add_option("--undo", "-U", "Recover server from the drain mode"); ``` They should be either one or the other. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
