mirror of
https://github.com/redmine/redmine.git
synced 2025-11-01 19:05:51 +01:00
scm: mercurial: use long id in adapter level (#14361)
git-svn-id: http://svn.redmine.org/redmine/trunk@12752 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
changeset = 'This template must be used with --debug option\n'
|
||||
changeset_quiet = 'This template must be used with --debug option\n'
|
||||
changeset_verbose = 'This template must be used with --debug option\n'
|
||||
changeset_debug = '<logentry revision="{rev}" node="{node|short}">\n<author>{author|escape}</author>\n<date>{date|isodatesec}</date>\n<paths>\n{file_mods}{file_adds}{file_dels}{file_copies}</paths>\n<msg>{desc|escape}</msg>\n<parents>\n{parents}</parents>\n</logentry>\n\n'
|
||||
changeset_debug = '<logentry revision="{rev}" node="{node}">\n<author>{author|escape}</author>\n<date>{date|isodatesec}</date>\n<paths>\n{file_mods}{file_adds}{file_dels}{file_copies}</paths>\n<msg>{desc|escape}</msg>\n<parents>\n{parents}</parents>\n</logentry>\n\n'
|
||||
|
||||
file_mod = '<path action="M">{file_mod|urlescape}</path>\n'
|
||||
file_add = '<path action="A">{file_add|urlescape}</path>\n'
|
||||
file_del = '<path action="D">{file_del|urlescape}</path>\n'
|
||||
file_copy = '<path-copied copyfrom-path="{source|urlescape}">{name|urlescape}</path-copied>\n'
|
||||
parent = '<parent>{node|short}</parent>\n'
|
||||
parent = '<parent>{node}</parent>\n'
|
||||
header='<?xml version="1.0" encoding="UTF-8" ?>\n<log>\n\n'
|
||||
# footer="</log>"
|
||||
|
||||
@@ -16,7 +16,7 @@ I/O encoding:
|
||||
:file path: urlencoded, raw string
|
||||
:tag name: utf-8
|
||||
:branch name: utf-8
|
||||
:node: 12-digits (short) hex string
|
||||
:node: hex string
|
||||
|
||||
Output example of rhsummary::
|
||||
|
||||
@@ -60,7 +60,7 @@ def _tip(ui, repo):
|
||||
return repo.changelog.count() - 1
|
||||
tipctx = repo.changectx(tiprev())
|
||||
ui.write('<tip revision="%d" node="%s"/>\n'
|
||||
% (tipctx.rev(), _x(node.short(tipctx.node()))))
|
||||
% (tipctx.rev(), _x(node.hex(tipctx.node()))))
|
||||
|
||||
_SPECIAL_TAGS = ('tip',)
|
||||
|
||||
@@ -74,7 +74,7 @@ def _tags(ui, repo):
|
||||
except error.LookupError:
|
||||
continue
|
||||
ui.write('<tag revision="%d" node="%s" name="%s"/>\n'
|
||||
% (r, _x(node.short(n)), _x(t)))
|
||||
% (r, _x(node.hex(n)), _x(t)))
|
||||
|
||||
def _branches(ui, repo):
|
||||
# see mercurial/commands.py:branches
|
||||
@@ -89,7 +89,7 @@ def _branches(ui, repo):
|
||||
for t, n, r in sorted(iterbranches(), key=lambda e: e[2], reverse=True):
|
||||
if repo.lookup(r) in branchheads(t):
|
||||
ui.write('<branch revision="%d" node="%s" name="%s"/>\n'
|
||||
% (r, _x(node.short(n)), _x(t)))
|
||||
% (r, _x(node.hex(n)), _x(t)))
|
||||
|
||||
def _manifest(ui, repo, path, rev):
|
||||
ctx = repo.changectx(rev)
|
||||
@@ -114,7 +114,7 @@ def _manifest(ui, repo, path, rev):
|
||||
tm, tzoffset = fctx.date()
|
||||
ui.write('<file name="%s" revision="%d" node="%s" '
|
||||
'time="%d" size="%d"/>\n'
|
||||
% (_u(name), fctx.rev(), _x(node.short(fctx.node())),
|
||||
% (_u(name), fctx.rev(), _x(node.hex(fctx.node())),
|
||||
tm, fctx.size(), ))
|
||||
|
||||
ui.write('</manifest>\n')
|
||||
|
||||
Reference in New Issue
Block a user