Show More
@@ -803,11 +803,11 b' class changeset_printer(object):' | |||
|
803 | 803 | |
|
804 | 804 | def showpatch(self, node): |
|
805 | 805 | if self.patch: |
|
806 | stat = self.diffopts.get('stat') | |
|
807 | diffopts = patch.diffopts(self.ui, self.diffopts) | |
|
806 | 808 | prev = self.repo.changelog.parents(node)[0] |
|
807 | chunks = patch.diffui(self.repo, prev, node, match=self.patch, | |
|
808 |
|
|
|
809 | for chunk, label in chunks: | |
|
810 | self.ui.write(chunk, label=label) | |
|
809 | diffordiffstat(self.ui, self.repo, diffopts, prev, node, | |
|
810 | match=self.patch, stat=stat) | |
|
811 | 811 | self.ui.write("\n") |
|
812 | 812 | |
|
813 | 813 | def _meaningful_parentrevs(self, log, rev): |
@@ -939,7 +939,7 b' def show_changeset(ui, repo, opts, buffe' | |||
|
939 | 939 | """ |
|
940 | 940 | # options |
|
941 | 941 | patch = False |
|
942 | if opts.get('patch'): | |
|
942 | if opts.get('patch') or opts.get('stat'): | |
|
943 | 943 | patch = matchfn or matchall(repo) |
|
944 | 944 | |
|
945 | 945 | tmpl = opts.get('template') |
@@ -3462,6 +3462,7 b' logopts = [' | |||
|
3462 | 3462 | ('g', 'git', None, _('use git extended diff format')), |
|
3463 | 3463 | ('l', 'limit', '', _('limit number of changes displayed')), |
|
3464 | 3464 | ('M', 'no-merges', None, _('do not show merges')), |
|
3465 | ('', 'stat', None, _('output diffstat-style summary of changes')), | |
|
3465 | 3466 | ] + templateopts |
|
3466 | 3467 | |
|
3467 | 3468 | diffopts = [ |
@@ -171,7 +171,7 b' diff: rev, change, text, git, nodates, s' | |||
|
171 | 171 | export: output, switch-parent, rev, text, git, nodates |
|
172 | 172 | forget: include, exclude |
|
173 | 173 | init: ssh, remotecmd |
|
174 | log: follow, follow-first, date, copies, keyword, rev, removed, only-merges, user, only-branch, branch, prune, patch, git, limit, no-merges, style, template, include, exclude | |
|
174 | log: follow, follow-first, date, copies, keyword, rev, removed, only-merges, user, only-branch, branch, prune, patch, git, limit, no-merges, stat, style, template, include, exclude | |
|
175 | 175 | merge: force, rev, preview |
|
176 | 176 | pull: update, force, rev, branch, ssh, remotecmd |
|
177 | 177 | push: force, rev, branch, ssh, remotecmd |
@@ -210,10 +210,10 b' heads: rev, topo, active, closed, style,' | |||
|
210 | 210 | help: |
|
211 | 211 | identify: rev, num, id, branch, tags |
|
212 | 212 | import: strip, base, force, no-commit, exact, import-branch, message, logfile, date, user, similarity |
|
213 | incoming: force, newest-first, bundle, rev, branch, patch, git, limit, no-merges, style, template, ssh, remotecmd | |
|
213 | incoming: force, newest-first, bundle, rev, branch, patch, git, limit, no-merges, stat, style, template, ssh, remotecmd | |
|
214 | 214 | locate: rev, print0, fullpath, include, exclude |
|
215 | 215 | manifest: rev |
|
216 | outgoing: force, rev, newest-first, branch, patch, git, limit, no-merges, style, template, ssh, remotecmd | |
|
216 | outgoing: force, rev, newest-first, branch, patch, git, limit, no-merges, stat, style, template, ssh, remotecmd | |
|
217 | 217 | parents: rev, style, template |
|
218 | 218 | paths: |
|
219 | 219 | recover: |
@@ -121,6 +121,9 b' hg log -d -1' | |||
|
121 | 121 | echo '% log -p -l2 --color=always' |
|
122 | 122 | hg --config extensions.color= log -p -l2 --color=always |
|
123 | 123 | |
|
124 | echo '% log -r tip --stat' | |
|
125 | hg log -r tip --stat | |
|
126 | ||
|
124 | 127 | cd .. |
|
125 | 128 | |
|
126 | 129 | hg init usertest |
@@ -306,6 +306,16 b' summary: m12' | |||
|
306 | 306 | [0;35m@@ -0,0 +1,1 @@[0m |
|
307 | 307 | [0;32m+b2[0m |
|
308 | 308 | |
|
309 | % log -r tip --stat | |
|
310 | changeset: 6:2404bbcab562 | |
|
311 | tag: tip | |
|
312 | user: test | |
|
313 | date: Thu Jan 01 00:00:01 1970 +0000 | |
|
314 | summary: b1.1 | |
|
315 | ||
|
316 | b1 | 1 + | |
|
317 | 1 files changed, 1 insertions(+), 0 deletions(-) | |
|
318 | ||
|
309 | 319 | adding a |
|
310 | 320 | adding b |
|
311 | 321 | changeset: 0:29a4c94f1924 |
General Comments 0
You need to be logged in to leave comments.
Login now