Mercurial > jhg
comparison src/com/tmate/hgkit/console/Log.java @ 50:f1db8610da62
Log to consult (placeholder, for now) class to find out associated tags
author | Artem Tikhomirov <tikhomirov.artem@gmail.com> |
---|---|
date | Sat, 15 Jan 2011 01:41:49 +0100 |
parents | 26e3eeaa3962 |
children | 613c936d74e4 |
comparison
equal
deleted
inserted
replaced
49:26e3eeaa3962 | 50:f1db8610da62 |
---|---|
149 | 149 |
150 private String print(int revNumber, Nodeid csetNodeid, Changeset cset) { | 150 private String print(int revNumber, Nodeid csetNodeid, Changeset cset) { |
151 StringBuilder sb = new StringBuilder(); | 151 StringBuilder sb = new StringBuilder(); |
152 Formatter f = new Formatter(sb); | 152 Formatter f = new Formatter(sb); |
153 f.format("changeset: %d:%s\n", revNumber, complete ? csetNodeid : csetNodeid.shortNotation()); | 153 f.format("changeset: %d:%s\n", revNumber, complete ? csetNodeid : csetNodeid.shortNotation()); |
154 if (revNumber == tip) { | 154 if (revNumber == tip || repo.getTags().isTagged(csetNodeid)) { |
155 sb.append("tag: tip\n"); | 155 |
156 sb.append("tag: "); | |
157 for (String t : repo.getTags().tags(csetNodeid)) { | |
158 sb.append(t); | |
159 sb.append(' '); | |
160 } | |
161 if (revNumber == tip) { | |
162 sb.append("tip"); | |
163 } | |
164 sb.append('\n'); | |
156 } | 165 } |
157 if (complete) { | 166 if (complete) { |
158 if (changelogWalker == null) { | 167 if (changelogWalker == null) { |
159 changelogWalker = repo.getChangelog().new ParentWalker(); | 168 changelogWalker = repo.getChangelog().new ParentWalker(); |
160 changelogWalker.init(); | 169 changelogWalker.init(); |