mirror of
https://github.com/openSUSE/osc.git
synced 2025-02-26 12:12: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)
|
subprocess.call('%s %s' % (editor, filename), shell=True)
|
||||||
mtime = os.stat(filename).st_mtime
|
mtime = os.stat(filename).st_mtime
|
||||||
|
|
||||||
if mtime_orig < mtime:
|
msg = open(filename).read().split(delim)[0].rstrip()
|
||||||
msg = open(filename).read()
|
|
||||||
os.unlink(filename)
|
if len(msg):
|
||||||
return msg.split(delim)[0].rstrip()
|
break
|
||||||
else:
|
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: ')
|
'a)bort, c)ontinue, e)dit: ')
|
||||||
if input in 'aA':
|
if input in 'aA':
|
||||||
os.unlink(filename)
|
os.unlink(filename)
|
||||||
raise oscerr.UserAbort
|
raise oscerr.UserAbort
|
||||||
elif input in 'cC':
|
elif input in 'cC':
|
||||||
os.unlink(filename)
|
break
|
||||||
return ''
|
|
||||||
elif input in 'eE':
|
elif input in 'eE':
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
os.unlink(filename)
|
||||||
|
return msg
|
||||||
|
|
||||||
|
|
||||||
def create_delete_request(apiurl, project, package, message):
|
def create_delete_request(apiurl, project, package, message):
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user