From b5560955028a695000935d3dacaf9581b2ee62d7 Mon Sep 17 00:00:00 2001 From: lethliel Date: Wed, 16 Oct 2019 14:07:40 +0200 Subject: [PATCH] implement incoming option for osc rq There is a config option 'include_request_from_project' which can be set to 0 to exclude all requests originating from the project in osc [rq|review] list. To force this behaviour just once (without always editing oscrc the '--incoming' option can be used. --- osc/commandline.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/osc/commandline.py b/osc/commandline.py index 4700919f..b24d742b 100644 --- a/osc/commandline.py +++ b/osc/commandline.py @@ -2122,6 +2122,8 @@ Please submit there instead, or use --nodevelproject to force direct submission. help='non-interactive review of request') @cmdln.option('--exclude-target-project', action='append', help='exclude target project from request list') + @cmdln.option('--incoming', action='store_true', + help='Show only requests where the project is target') @cmdln.option('--involved-projects', action='store_true', help='show all requests for project/packages where USER is involved') @cmdln.option('--target-package-filter', metavar='TARGET_PACKAGE_FILTER', @@ -2233,6 +2235,9 @@ Please submit there instead, or use --nodevelproject to force direct submission. if opts.state == '' and subcmd != 'review': opts.state = 'declined,new,review' + if opts.incoming: + conf.config['include_request_from_project'] = False + if args[0] == 'help': return self.do_help(['help', 'request'])