Show More
@@ -2775,20 +2775,20 b' def identify(ui, repo, source=None, rev=' | |||||
2775 | for p in parents: |
|
2775 | for p in parents: | |
2776 | taglist.extend(p.tags()) |
|
2776 | taglist.extend(p.tags()) | |
2777 |
|
2777 | |||
2778 |
|
|
2778 | dirty = "" | |
2779 | if (any(repo.status()) |
|
2779 | if (any(repo.status()) | |
2780 | or any(ctx.sub(s).dirty() for s in ctx.substate)): |
|
2780 | or any(ctx.sub(s).dirty() for s in ctx.substate)): | |
2781 |
|
|
2781 | dirty = '+' | |
2782 |
fm.data( |
|
2782 | fm.data(dirty=dirty) | |
2783 |
|
2783 | |||
2784 | hexoutput = [hexfunc(p.node()) for p in parents] |
|
2784 | hexoutput = [hexfunc(p.node()) for p in parents] | |
2785 | if default or id: |
|
2785 | if default or id: | |
2786 |
output = ["%s%s" % ('+'.join(hexoutput), |
|
2786 | output = ["%s%s" % ('+'.join(hexoutput), dirty)] | |
2787 |
fm.data(id="%s%s" % ('+'.join(hexoutput), |
|
2787 | fm.data(id="%s%s" % ('+'.join(hexoutput), dirty)) | |
2788 |
|
2788 | |||
2789 | if num: |
|
2789 | if num: | |
2790 | numoutput = ["%d" % p.rev() for p in parents] |
|
2790 | numoutput = ["%d" % p.rev() for p in parents] | |
2791 |
output.append("%s%s" % ('+'.join(numoutput), |
|
2791 | output.append("%s%s" % ('+'.join(numoutput), dirty)) | |
2792 |
|
2792 | |||
2793 | for i, p in enumerate(parents): |
|
2793 | for i, p in enumerate(parents): | |
2794 | fn = fm.nested('p%d' % (i + 1)) |
|
2794 | fn = fm.nested('p%d' % (i + 1)) |
@@ -48,7 +48,7 b' with options' | |||||
48 | { |
|
48 | { | |
49 | "bookmarks": [], |
|
49 | "bookmarks": [], | |
50 | "branch": "default", |
|
50 | "branch": "default", | |
51 |
" |
|
51 | "dirty": "", | |
52 | "id": "cb9a9f314b8b", |
|
52 | "id": "cb9a9f314b8b", | |
53 | "node": "ffffffffffffffffffffffffffffffffffffffff", |
|
53 | "node": "ffffffffffffffffffffffffffffffffffffffff", | |
54 | "p1": [{"node": "cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b", "rev": 0}], |
|
54 | "p1": [{"node": "cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b", "rev": 0}], | |
@@ -66,7 +66,7 b' with modifications' | |||||
66 | { |
|
66 | { | |
67 | "bookmarks": [], |
|
67 | "bookmarks": [], | |
68 | "branch": "default", |
|
68 | "branch": "default", | |
69 |
" |
|
69 | "dirty": "+", | |
70 | "id": "cb9a9f314b8b+", |
|
70 | "id": "cb9a9f314b8b+", | |
71 | "node": "ffffffffffffffffffffffffffffffffffffffff", |
|
71 | "node": "ffffffffffffffffffffffffffffffffffffffff", | |
72 | "p1": [{"node": "cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b", "rev": 0}], |
|
72 | "p1": [{"node": "cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b", "rev": 0}], |
@@ -54,7 +54,7 b' Should succeed:' | |||||
54 | { |
|
54 | { | |
55 | "bookmarks": [], |
|
55 | "bookmarks": [], | |
56 | "branch": "default", |
|
56 | "branch": "default", | |
57 |
" |
|
57 | "dirty": "+", | |
58 | "id": "f25cbe84d8b3+2d95304fed5d+", |
|
58 | "id": "f25cbe84d8b3+2d95304fed5d+", | |
59 | "node": "ffffffffffffffffffffffffffffffffffffffff", |
|
59 | "node": "ffffffffffffffffffffffffffffffffffffffff", | |
60 | "p1": [{"node": "f25cbe84d8b320e298e7703f18a25a3959518c23", "rev": 4}], |
|
60 | "p1": [{"node": "f25cbe84d8b320e298e7703f18a25a3959518c23", "rev": 4}], |
General Comments 0
You need to be logged in to leave comments.
Login now