From 4b456b402b6ae7c493d228db8620aa496838402d Mon Sep 17 00:00:00 2001 From: Athanasius Date: Mon, 12 Apr 2021 16:35:39 +0100 Subject: [PATCH] EDMarketConnector: Mutually exclude --force-localserver-for-auth --force-edmc-protocol --- EDMarketConnector.py | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/EDMarketConnector.py b/EDMarketConnector.py index b996760c..22d91ecd 100755 --- a/EDMarketConnector.py +++ b/EDMarketConnector.py @@ -85,15 +85,16 @@ if __name__ == '__main__': # noqa: C901 action='store_true' ) - parser.add_argument('--force-localserver-for-auth', - help='Force EDMC to use a localhost webserver for Frontier Auth callback', - action='store_true' - ) + auth_options = parser.add_mutually_exclusive_group(required=False) + auth_options.add_argument('--force-localserver-for-auth', + help='Force EDMC to use a localhost webserver for Frontier Auth callback', + action='store_true' + ) - parser.add_argument('--force-edmc-protocol', - help='Force use of the edmc:// protocol handler. Error if not on Windows', - action='store_true', - ) + auth_options.add_argument('--force-edmc-protocol', + help='Force use of the edmc:// protocol handler. Error if not on Windows', + action='store_true', + ) parser.add_argument('edmc', help='Callback from Frontier Auth',