equal
deleted
inserted
replaced
18 topic = repo.currenttopic |
18 topic = repo.currenttopic |
19 if not topic: |
19 if not topic: |
20 raise error.Abort(_('no active topic to list')) |
20 raise error.Abort(_('no active topic to list')) |
21 for idx, r in enumerate(getstack(repo, topic)): |
21 for idx, r in enumerate(getstack(repo, topic)): |
22 # super crude initial version |
22 # super crude initial version |
23 l = "t%d: %s\n" % (idx, repo[r].description().splitlines()[0]) |
23 symbol = ':' |
|
24 state = 'clean' |
|
25 if repo.revs('%d and parents()', r): |
|
26 symbol = '@' |
|
27 state = 'current' |
|
28 if repo.revs('%d and unstable()', r): |
|
29 symbol = '$' |
|
30 state = 'unstable' |
|
31 if state == 'clean': |
|
32 l = "t%d%s %s\n" % (idx, symbol, |
|
33 repo[r].description().splitlines()[0]) |
|
34 else: |
|
35 l = "t%d%s %s (%s)\n" % (idx, symbol, |
|
36 repo[r].description().splitlines()[0], |
|
37 state) |
24 ui.write(l) |
38 ui.write(l) |
25 |
39 |
26 # Copied from evolve 081605c2e9b6 |
40 # Copied from evolve 081605c2e9b6 |
27 |
41 |
28 def _orderrevs(repo, revs): |
42 def _orderrevs(repo, revs): |