Show More
@@ -18,7 +18,7 def difftree(args, ui, repo): | |||||
18 | if node2: |
|
18 | if node2: | |
19 | change = repo.changelog.read(node2) |
|
19 | change = repo.changelog.read(node2) | |
20 | mmap2 = repo.manifest.read(change[0]) |
|
20 | mmap2 = repo.manifest.read(change[0]) | |
21 |
(c, a, d) = repo. |
|
21 | (c, a, d, u) = repo.changes(node1, node2) | |
22 | def read(f): return repo.file(f).read(mmap2[f]) |
|
22 | def read(f): return repo.file(f).read(mmap2[f]) | |
23 | date2 = date(change) |
|
23 | date2 = date(change) | |
24 | else: |
|
24 | else: | |
@@ -51,8 +51,7 def difftree(args, ui, repo): | |||||
51 | doptions = {} |
|
51 | doptions = {} | |
52 | opts = [('p', 'patch', None, 'patch'), |
|
52 | opts = [('p', 'patch', None, 'patch'), | |
53 | ('r', 'recursive', None, 'recursive')] |
|
53 | ('r', 'recursive', None, 'recursive')] | |
54 |
args = fancyopts.fancyopts(args, opts, doptions |
|
54 | args = fancyopts.fancyopts(args, opts, doptions) | |
55 | 'hg diff-tree [options] sha1 sha1') |
|
|||
56 |
|
55 | |||
57 | if len(args) < 2: |
|
56 | if len(args) < 2: | |
58 | help() |
|
57 | help() | |
@@ -61,7 +60,7 def difftree(args, ui, repo): | |||||
61 | revs.append(repo.lookup(args[1])) |
|
60 | revs.append(repo.lookup(args[1])) | |
62 | args = args[2:] |
|
61 | args = args[2:] | |
63 | if doptions['patch']: |
|
62 | if doptions['patch']: | |
64 |
commands.dodiff(ui, repo |
|
63 | commands.dodiff(sys.stdout, ui, repo, args, *revs) | |
65 | else: |
|
64 | else: | |
66 | __difftree(repo, args, *revs) |
|
65 | __difftree(repo, args, *revs) | |
67 |
|
66 | |||
@@ -87,8 +86,7 def catcommit(repo, n, prefix): | |||||
87 | def catfile(args, ui, repo): |
|
86 | def catfile(args, ui, repo): | |
88 | doptions = {} |
|
87 | doptions = {} | |
89 | opts = [('s', 'stdin', None, 'stdin')] |
|
88 | opts = [('s', 'stdin', None, 'stdin')] | |
90 |
args = fancyopts.fancyopts(args, opts, doptions |
|
89 | args = fancyopts.fancyopts(args, opts, doptions) | |
91 | 'hg cat-file type sha1') |
|
|||
92 |
|
90 | |||
93 | # in stdin mode, every line except the commit is prefixed with two |
|
91 | # in stdin mode, every line except the commit is prefixed with two | |
94 | # spaces. This way the our caller can find the commit without magic |
|
92 | # spaces. This way the our caller can find the commit without magic | |
@@ -209,8 +207,7 def revlist(args, repo): | |||||
209 | doptions = {} |
|
207 | doptions = {} | |
210 | opts = [('c', 'commit', None, 'commit'), |
|
208 | opts = [('c', 'commit', None, 'commit'), | |
211 | ('n', 'max-nr', 0, 'max-nr')] |
|
209 | ('n', 'max-nr', 0, 'max-nr')] | |
212 |
args = fancyopts.fancyopts(args, opts, doptions |
|
210 | args = fancyopts.fancyopts(args, opts, doptions) | |
213 | 'hg rev-list') |
|
|||
214 | if doptions['commit']: |
|
211 | if doptions['commit']: | |
215 | full = "commit" |
|
212 | full = "commit" | |
216 | else: |
|
213 | else: |
General Comments 0
You need to be logged in to leave comments.
Login now