1
0
mirror of https://github.com/openSUSE/osc.git synced 2024-12-26 09:56:13 +01:00

- osc buildhist: change the output into a format which better matches actual RPM filenames.

- give commit message tempfiles a ".diff" suffix, so syntax highlighting might work in some editors
This commit is contained in:
Dr. Peter Poeml 2008-06-17 06:12:48 +00:00
parent 7ee4444b6b
commit 2bd196d8e3
2 changed files with 5 additions and 3 deletions

View File

@ -1400,6 +1400,7 @@ Please submit there instead, or use --nodevelproject to force direct submission.
print ''.join(show_results_meta(pac.apiurl, pac.prjname, package=pac.name))
@cmdln.alias('r')
def do_results(self, subcmd, opts, *args):
"""${cmd_name}: Shows the build results of a package
@ -1440,6 +1441,7 @@ Please submit there instead, or use --nodevelproject to force direct submission.
@cmdln.option('-n', '--name-filter', metavar='EXPR',
help='show only packages whos name matches EXPR')
@cmdln.alias('pr')
def do_prjresults(self, subcmd, opts, *args):
"""${cmd_name}: Shows project-wide build results

View File

@ -1805,7 +1805,7 @@ def read_meta_from_spec(specfile, *args):
def edit_message(footer=''):
delim = '--This line, and those below, will be ignored--\n\n' + footer
import tempfile
(fd, filename) = tempfile.mkstemp(prefix = 'osc-commitmsg', suffix = '.txt', dir = '/tmp')
(fd, filename) = tempfile.mkstemp(prefix = 'osc-commitmsg', suffix = '.diff', dir = '/tmp')
f = os.fdopen(fd, 'w')
f.write('\n')
f.write(delim)
@ -2666,9 +2666,9 @@ def get_buildhistory(apiurl, prj, package, platform, arch):
t = time.localtime(int(node.get('time')))
t = time.strftime('%Y-%m-%d %H:%M:%S', t)
r.append('%s %s %6d %2d %s' % (t, srcmd5, rev, bcnt, versrel))
r.append('%s %s %6d %s.%d' % (t, srcmd5, rev, versrel, bcnt))
r.insert(0, 'time srcmd5 rev bcnt vers-rel')
r.insert(0, 'time srcmd5 rev vers-rel.bcnt')
return r