mirror of
https://github.com/openSUSE/osc.git
synced 2025-02-26 04:02:11 +01:00
unchanged log message is no error
This commit is contained in:
parent
5da4957347
commit
0b1e0b89ea
16
osc/core.py
16
osc/core.py
@ -2458,22 +2458,24 @@ def edit_message(footer='', template=''):
|
||||
subprocess.call('%s %s' % (editor, filename), shell=True)
|
||||
mtime = os.stat(filename).st_mtime
|
||||
|
||||
if mtime_orig < mtime:
|
||||
msg = open(filename).read()
|
||||
os.unlink(filename)
|
||||
return msg.split(delim)[0].rstrip()
|
||||
msg = open(filename).read().split(delim)[0].rstrip()
|
||||
|
||||
if len(msg):
|
||||
break
|
||||
else:
|
||||
input = raw_input('Log message unchanged or not specified\n'
|
||||
input = raw_input('Log message not specified\n'
|
||||
'a)bort, c)ontinue, e)dit: ')
|
||||
if input in 'aA':
|
||||
os.unlink(filename)
|
||||
raise oscerr.UserAbort
|
||||
elif input in 'cC':
|
||||
os.unlink(filename)
|
||||
return ''
|
||||
break
|
||||
elif input in 'eE':
|
||||
pass
|
||||
|
||||
os.unlink(filename)
|
||||
return msg
|
||||
|
||||
|
||||
def create_delete_request(apiurl, project, package, message):
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user