From c86093bc68de09565af256e79228df0ffced6741 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dirk=20M=C3=BCller?= Date: Thu, 7 Dec 2023 16:59:19 +0100 Subject: [PATCH] Allow -X HEAD on osc api requests as well In some cases the exit code is all you want --- osc/commandline.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/osc/commandline.py b/osc/commandline.py index b7c19bc63e..2d334aab8d 100644 --- a/osc/commandline.py +++ b/osc/commandline.py @@ -8747,8 +8747,8 @@ def do_importsrcpkg(self, subcmd, opts): print('Package \'%s\' imported successfully' % pac) @cmdln.option('-X', '-m', '--method', default='GET', metavar='HTTP_METHOD', - choices=('GET', 'PUT', 'POST', 'DELETE'), - help='specify HTTP method to use (GET|PUT|DELETE|POST)') + choices=('HEAD', 'GET', 'PUT', 'POST', 'DELETE'), + help='specify HTTP method to use (HEAD|GET|PUT|DELETE|POST)') @cmdln.option('-e', '--edit', default=None, action='store_true', help='GET, edit and PUT the location') @cmdln.option('-d', '--data', default=None, metavar='STRING',