equal
deleted
inserted
replaced
3 from __future__ import absolute_import |
3 from __future__ import absolute_import |
4 |
4 |
5 from mercurial import ( |
5 from mercurial import ( |
6 error, |
6 error, |
7 patch, |
7 patch, |
|
8 pycompat, |
8 registrar, |
9 registrar, |
9 scmutil, |
10 scmutil, |
10 ) |
11 ) |
11 |
12 |
12 cmdtable = {} |
13 cmdtable = {} |
14 |
15 |
15 @command(b'autodiff', |
16 @command(b'autodiff', |
16 [(b'', b'git', b'', b'git upgrade mode (yes/no/auto/warn/abort)')], |
17 [(b'', b'git', b'', b'git upgrade mode (yes/no/auto/warn/abort)')], |
17 b'[OPTION]... [FILE]...') |
18 b'[OPTION]... [FILE]...') |
18 def autodiff(ui, repo, *pats, **opts): |
19 def autodiff(ui, repo, *pats, **opts): |
|
20 opts = pycompat.byteskwargs(opts) |
19 diffopts = patch.difffeatureopts(ui, opts) |
21 diffopts = patch.difffeatureopts(ui, opts) |
20 git = opts.get(b'git', b'no') |
22 git = opts.get(b'git', b'no') |
21 brokenfiles = set() |
23 brokenfiles = set() |
22 losedatafn = None |
24 losedatafn = None |
23 if git in (b'yes', b'no'): |
25 if git in (b'yes', b'no'): |