##// END OF EJS Templates
interfaces: create a new folder for interfaces and move repository.py in it...
Pulkit Goyal -
r43078:268662aa default
parent child Browse files
Show More
1 NO CONTENT: new file 100644
NO CONTENT: new file 100644
@@ -28,6 +28,7 b' allowsymbolimports = ('
28 'mercurial.hgweb.common',
28 'mercurial.hgweb.common',
29 'mercurial.hgweb.request',
29 'mercurial.hgweb.request',
30 'mercurial.i18n',
30 'mercurial.i18n',
31 'mercurial.interfaces',
31 'mercurial.node',
32 'mercurial.node',
32 # for revlog to re-export constant to extensions
33 # for revlog to re-export constant to extensions
33 'mercurial.revlogutils.constants',
34 'mercurial.revlogutils.constants',
@@ -141,13 +141,16 b' from mercurial import ('
141 minifileset,
141 minifileset,
142 node,
142 node,
143 pycompat,
143 pycompat,
144 repository,
145 revlog,
144 revlog,
146 scmutil,
145 scmutil,
147 templateutil,
146 templateutil,
148 util,
147 util,
149 )
148 )
150
149
150 from mercurial.interfaces import (
151 repository,
152 )
153
151 from . import (
154 from . import (
152 blobstore,
155 blobstore,
153 wireprotolfsserver,
156 wireprotolfsserver,
@@ -21,7 +21,6 b' from mercurial import ('
21 exchange,
21 exchange,
22 exthelper,
22 exthelper,
23 localrepo,
23 localrepo,
24 repository,
25 revlog,
24 revlog,
26 scmutil,
25 scmutil,
27 upgrade,
26 upgrade,
@@ -30,6 +29,10 b' from mercurial import ('
30 wireprotov1server,
29 wireprotov1server,
31 )
30 )
32
31
32 from mercurial.interfaces import (
33 repository,
34 )
35
33 from mercurial.utils import (
36 from mercurial.utils import (
34 storageutil,
37 storageutil,
35 stringutil,
38 stringutil,
@@ -17,6 +17,9 b" testedwith = 'ships-with-hg-core'"
17 from mercurial import (
17 from mercurial import (
18 localrepo,
18 localrepo,
19 registrar,
19 registrar,
20 )
21
22 from mercurial.interfaces import (
20 repository,
23 repository,
21 )
24 )
22
25
@@ -23,10 +23,12 b' from mercurial import ('
23 localrepo,
23 localrepo,
24 narrowspec,
24 narrowspec,
25 repair,
25 repair,
26 repository,
27 util,
26 util,
28 wireprototypes,
27 wireprototypes,
29 )
28 )
29 from mercurial.interfaces import (
30 repository,
31 )
30 from mercurial.utils import (
32 from mercurial.utils import (
31 stringutil,
33 stringutil,
32 )
34 )
@@ -25,12 +25,14 b' from mercurial import ('
25 pycompat,
25 pycompat,
26 registrar,
26 registrar,
27 repair,
27 repair,
28 repository,
29 repoview,
28 repoview,
30 sparse,
29 sparse,
31 util,
30 util,
32 wireprototypes,
31 wireprototypes,
33 )
32 )
33 from mercurial.interfaces import (
34 repository,
35 )
34
36
35 table = {}
37 table = {}
36 command = registrar.command(table)
38 command = registrar.command(table)
@@ -70,10 +70,12 b' from mercurial import ('
70 mdiff,
70 mdiff,
71 pycompat,
71 pycompat,
72 registrar,
72 registrar,
73 repository,
74 util,
73 util,
75 verify,
74 verify,
76 )
75 )
76 from mercurial.interfaces import (
77 repository,
78 )
77 from mercurial.utils import (
79 from mercurial.utils import (
78 interfaceutil,
80 interfaceutil,
79 storageutil,
81 storageutil,
@@ -25,8 +25,11 b' from . import ('
25 mdiff,
25 mdiff,
26 phases,
26 phases,
27 pycompat,
27 pycompat,
28 util,
29 )
30
31 from .interfaces import (
28 repository,
32 repository,
29 util,
30 )
33 )
31
34
32 _CHANGEGROUPV1_DELTA_HEADER = struct.Struct("20s20s20s20s")
35 _CHANGEGROUPV1_DELTA_HEADER = struct.Struct("20s20s20s20s")
@@ -34,7 +34,6 b' from . import ('
34 phases,
34 phases,
35 pushkey,
35 pushkey,
36 pycompat,
36 pycompat,
37 repository,
38 scmutil,
37 scmutil,
39 sslutil,
38 sslutil,
40 streamclone,
39 streamclone,
@@ -42,6 +41,9 b' from . import ('
42 util,
41 util,
43 wireprototypes,
42 wireprototypes,
44 )
43 )
44 from .interfaces import (
45 repository,
46 )
45 from .utils import (
47 from .utils import (
46 stringutil,
48 stringutil,
47 )
49 )
@@ -22,8 +22,10 b' from . import ('
22 narrowspec,
22 narrowspec,
23 phases,
23 phases,
24 pycompat,
24 pycompat,
25 setdiscovery,
26 )
27 from .interfaces import (
25 repository,
28 repository,
26 setdiscovery,
27 )
29 )
28
30
29 def pull(pullop):
31 def pull(pullop):
@@ -14,8 +14,10 b' from .node import ('
14 )
14 )
15 from . import (
15 from . import (
16 error,
16 error,
17 revlog,
18 )
19 from .interfaces import (
17 repository,
20 repository,
18 revlog,
19 )
21 )
20 from .utils import (
22 from .utils import (
21 interfaceutil,
23 interfaceutil,
@@ -39,7 +39,6 b' from . import ('
39 node,
39 node,
40 phases,
40 phases,
41 pycompat,
41 pycompat,
42 repository as repositorymod,
43 scmutil,
42 scmutil,
44 sshpeer,
43 sshpeer,
45 statichttprepo,
44 statichttprepo,
@@ -51,6 +50,10 b' from . import ('
51 vfs as vfsmod,
50 vfs as vfsmod,
52 )
51 )
53
52
53 from .interfaces import (
54 repository as repositorymod,
55 )
56
54 release = lock.release
57 release = lock.release
55
58
56 # shared features
59 # shared features
@@ -16,12 +16,14 b' import struct'
16 import weakref
16 import weakref
17
17
18 from .i18n import _
18 from .i18n import _
19 from .interfaces import (
20 repository,
21 )
19 from . import (
22 from . import (
20 bundle2,
23 bundle2,
21 error,
24 error,
22 httpconnection,
25 httpconnection,
23 pycompat,
26 pycompat,
24 repository,
25 statichttprepo,
27 statichttprepo,
26 url as urlmod,
28 url as urlmod,
27 util,
29 util,
@@ -7,11 +7,11 b''
7
7
8 from __future__ import absolute_import
8 from __future__ import absolute_import
9
9
10 from .i18n import _
10 from ..i18n import _
11 from . import (
11 from .. import (
12 error,
12 error,
13 )
13 )
14 from .utils import (
14 from ..utils import (
15 interfaceutil,
15 interfaceutil,
16 )
16 )
17
17
@@ -52,7 +52,6 b' from . import ('
52 phases,
52 phases,
53 pushkey,
53 pushkey,
54 pycompat,
54 pycompat,
55 repository,
56 repoview,
55 repoview,
57 revset,
56 revset,
58 revsetlang,
57 revsetlang,
@@ -66,6 +65,11 b' from . import ('
66 util,
65 util,
67 vfs as vfsmod,
66 vfs as vfsmod,
68 )
67 )
68
69 from .interfaces import (
70 repository,
71 )
72
69 from .utils import (
73 from .utils import (
70 interfaceutil,
74 interfaceutil,
71 procutil,
75 procutil,
@@ -24,10 +24,12 b' from . import ('
24 mdiff,
24 mdiff,
25 policy,
25 policy,
26 pycompat,
26 pycompat,
27 repository,
28 revlog,
27 revlog,
29 util,
28 util,
30 )
29 )
30 from .interfaces import (
31 repository,
32 )
31 from .utils import (
33 from .utils import (
32 interfaceutil,
34 interfaceutil,
33 )
35 )
@@ -8,11 +8,13 b''
8 from __future__ import absolute_import
8 from __future__ import absolute_import
9
9
10 from .i18n import _
10 from .i18n import _
11 from .interfaces import (
12 repository,
13 )
11 from . import (
14 from . import (
12 error,
15 error,
13 match as matchmod,
16 match as matchmod,
14 merge,
17 merge,
15 repository,
16 scmutil,
18 scmutil,
17 sparse,
19 sparse,
18 util,
20 util,
@@ -65,10 +65,12 b' from . import ('
65 mdiff,
65 mdiff,
66 policy,
66 policy,
67 pycompat,
67 pycompat,
68 repository,
69 templatefilters,
68 templatefilters,
70 util,
69 util,
71 )
70 )
71 from .interfaces import (
72 repository,
73 )
72 from .revlogutils import (
74 from .revlogutils import (
73 deltas as deltautil,
75 deltas as deltautil,
74 flagutil,
76 flagutil,
@@ -9,7 +9,7 b''
9
9
10 from __future__ import absolute_import
10 from __future__ import absolute_import
11
11
12 from .. import (
12 from ..interfaces import (
13 repository,
13 repository,
14 )
14 )
15
15
@@ -12,13 +12,15 b' import os'
12 import struct
12 import struct
13
13
14 from .i18n import _
14 from .i18n import _
15 from .interfaces import (
16 repository,
17 )
15 from . import (
18 from . import (
16 cacheutil,
19 cacheutil,
17 error,
20 error,
18 narrowspec,
21 narrowspec,
19 phases,
22 phases,
20 pycompat,
23 pycompat,
21 repository,
22 store,
24 store,
23 util,
25 util,
24 )
26 )
@@ -17,6 +17,8 b' from ..node import ('
17 from .. import (
17 from .. import (
18 error,
18 error,
19 mdiff,
19 mdiff,
20 )
21 from ..interfaces import (
20 repository,
22 repository,
21 )
23 )
22 from ..utils import (
24 from ..utils import (
@@ -22,8 +22,8 b' from .. import ('
22 error,
22 error,
23 mdiff,
23 mdiff,
24 pycompat,
24 pycompat,
25 repository,
26 )
25 )
26 from ..interfaces import repository
27
27
28 _nullhash = hashlib.sha1(nullid)
28 _nullhash = hashlib.sha1(nullid)
29
29
@@ -22,10 +22,12 b' from . import ('
22 error,
22 error,
23 pushkey as pushkeymod,
23 pushkey as pushkeymod,
24 pycompat,
24 pycompat,
25 repository,
26 util,
25 util,
27 wireprototypes,
26 wireprototypes,
28 )
27 )
28 from .interfaces import (
29 repository,
30 )
29 from .utils import (
31 from .utils import (
30 interfaceutil,
32 interfaceutil,
31 )
33 )
@@ -1067,6 +1067,7 b" packages = ['mercurial',"
1067 'mercurial.cext',
1067 'mercurial.cext',
1068 'mercurial.cffi',
1068 'mercurial.cffi',
1069 'mercurial.hgweb',
1069 'mercurial.hgweb',
1070 'mercurial.interfaces',
1070 'mercurial.pure',
1071 'mercurial.pure',
1071 'mercurial.thirdparty',
1072 'mercurial.thirdparty',
1072 'mercurial.thirdparty.attr',
1073 'mercurial.thirdparty.attr',
@@ -6,7 +6,8 b' then'
6 fi
6 fi
7
7
8 cat > notcapable-$CAP.py << EOF
8 cat > notcapable-$CAP.py << EOF
9 from mercurial import extensions, localrepo, repository
9 from mercurial import extensions, localrepo
10 from mercurial.interfaces import repository
10 def extsetup(ui):
11 def extsetup(ui):
11 extensions.wrapfunction(repository.peer, 'capable', wrapcapable)
12 extensions.wrapfunction(repository.peer, 'capable', wrapcapable)
12 extensions.wrapfunction(localrepo.localrepository, 'peer', wrappeer)
13 extensions.wrapfunction(localrepo.localrepository, 'peer', wrappeer)
@@ -13,6 +13,8 b' from mercurial import ('
13 error,
13 error,
14 extensions,
14 extensions,
15 localrepo,
15 localrepo,
16 )
17 from mercurial.interfaces import (
16 repository,
18 repository,
17 )
19 )
18
20
@@ -32,11 +32,13 b' from mercurial import ('
32 localrepo,
32 localrepo,
33 mdiff,
33 mdiff,
34 pycompat,
34 pycompat,
35 repository,
36 revlog,
35 revlog,
37 store,
36 store,
38 verify,
37 verify,
39 )
38 )
39 from mercurial.interfaces import (
40 repository,
41 )
40 from mercurial.utils import (
42 from mercurial.utils import (
41 cborutil,
43 cborutil,
42 interfaceutil,
44 interfaceutil,
@@ -14,6 +14,9 b" if subprocess.call(['python', '%s/hghave"
14 'test-repo']):
14 'test-repo']):
15 sys.exit(80)
15 sys.exit(80)
16
16
17 from mercurial.interfaces import (
18 repository,
19 )
17 from mercurial.thirdparty.zope import (
20 from mercurial.thirdparty.zope import (
18 interface as zi,
21 interface as zi,
19 )
22 )
@@ -27,7 +30,6 b' from mercurial import ('
27 localrepo,
30 localrepo,
28 manifest,
31 manifest,
29 pycompat,
32 pycompat,
30 repository,
31 revlog,
33 revlog,
32 sshpeer,
34 sshpeer,
33 statichttprepo,
35 statichttprepo,
@@ -10,12 +10,14 b' from __future__ import absolute_import'
10 from mercurial import (
10 from mercurial import (
11 extensions,
11 extensions,
12 registrar,
12 registrar,
13 repository,
14 util,
13 util,
15 wireprotoserver,
14 wireprotoserver,
16 wireprototypes,
15 wireprototypes,
17 wireprotov2server,
16 wireprotov2server,
18 )
17 )
18 from mercurial.interfaces import (
19 repository,
20 )
19 from mercurial.utils import (
21 from mercurial.utils import (
20 interfaceutil,
22 interfaceutil,
21 stringutil,
23 stringutil,
General Comments 0
You need to be logged in to leave comments. Login now