Mercurial > hg > mercurial-crew-with-dirclash
comparison hgext/mq.py @ 3698:a9090b264250
qrefresh: respect --git even in the slow path
author | Alexis S. L. Carvalho <alexis@cecm.usp.br> |
---|---|
date | Mon, 20 Nov 2006 19:32:41 -0200 |
parents | da262f35fbc8 |
children | 4bafcf7aeb32 |
comparison
equal
deleted
inserted
replaced
3697:da262f35fbc8 | 3698:a9090b264250 |
---|---|
964 comments.append(msg) | 964 comments.append(msg) |
965 if comments: | 965 if comments: |
966 comments = "\n".join(comments) + '\n\n' | 966 comments = "\n".join(comments) + '\n\n' |
967 patchf.write(comments) | 967 patchf.write(comments) |
968 | 968 |
969 if opts.get('git'): | |
970 self.diffopts().git = True | |
969 fns, matchfn, anypats = cmdutil.matchpats(repo, pats, opts) | 971 fns, matchfn, anypats = cmdutil.matchpats(repo, pats, opts) |
970 tip = repo.changelog.tip() | 972 tip = repo.changelog.tip() |
971 if top == tip: | 973 if top == tip: |
972 # if the top of our patch queue is also the tip, there is an | 974 # if the top of our patch queue is also the tip, there is an |
973 # optimization here. We update the dirstate in place and strip | 975 # optimization here. We update the dirstate in place and strip |
1019 | 1021 |
1020 m = util.unique(mm) | 1022 m = util.unique(mm) |
1021 r = util.unique(dd) | 1023 r = util.unique(dd) |
1022 a = util.unique(aa) | 1024 a = util.unique(aa) |
1023 filelist = filter(matchfn, util.unique(m + r + a)) | 1025 filelist = filter(matchfn, util.unique(m + r + a)) |
1024 if opts.get('git'): | |
1025 self.diffopts().git = True | |
1026 patch.diff(repo, patchparent, files=filelist, match=matchfn, | 1026 patch.diff(repo, patchparent, files=filelist, match=matchfn, |
1027 fp=patchf, changes=(m, a, r, [], u), | 1027 fp=patchf, changes=(m, a, r, [], u), |
1028 opts=self.diffopts()) | 1028 opts=self.diffopts()) |
1029 patchf.close() | 1029 patchf.close() |
1030 | 1030 |