mirror of
https://github.com/openSUSE/osc.git
synced 2024-11-10 14:56:14 +01:00
- do_submitrequest: automatically supersede existing requests if "--yes" was specified
Fixes #58
This commit is contained in:
parent
a7ea5043ae
commit
6a36b5180a
@ -1409,8 +1409,8 @@ Please submit there instead, or use --nodevelproject to force direct submission.
|
||||
reqs = get_request_list(apiurl, dst_project, dst_package, req_type='submit', req_state=['new','review'])
|
||||
user = conf.get_apiurl_usr(apiurl)
|
||||
myreqs = [ i for i in reqs if i.state.who == user ]
|
||||
repl = ''
|
||||
if len(myreqs) > 0:
|
||||
repl = 'y'
|
||||
if len(myreqs) > 0 and not opts.yes:
|
||||
print('You already created the following submit request: %s.' % \
|
||||
', '.join([i.reqid for i in myreqs ]))
|
||||
repl = raw_input('Supersede the old requests? (y/n/c) ')
|
||||
|
Loading…
Reference in New Issue
Block a user