Show More
@@ -26,7 +26,7 b' def check_clean(ui, repo):' | |||
|
26 | 26 | ui.warn("Repository is not clean, please commit or revert\n") |
|
27 | 27 | sys.exit(1) |
|
28 | 28 | |
|
29 | class bisect: | |
|
29 | class bisect(object): | |
|
30 | 30 | """dichotomic search in the DAG of changesets""" |
|
31 | 31 | def __init__(self, ui, repo): |
|
32 | 32 | self.repo = repo |
@@ -678,7 +678,7 b' def clone(ui, source, dest=None, **opts)' | |||
|
678 | 678 | |
|
679 | 679 | dest = os.path.realpath(dest) |
|
680 | 680 | |
|
681 | class Dircleanup: | |
|
681 | class Dircleanup(object): | |
|
682 | 682 | def __init__(self, dir_): |
|
683 | 683 | self.rmtree = shutil.rmtree |
|
684 | 684 | self.dir_ = dir_ |
@@ -1188,7 +1188,7 b' def grep(ui, repo, pattern, *pats, **opt' | |||
|
1188 | 1188 | yield linenum, mstart - lstart, mend - lstart, body[lstart:lend] |
|
1189 | 1189 | begin = lend + 1 |
|
1190 | 1190 | |
|
1191 | class linestate: | |
|
1191 | class linestate(object): | |
|
1192 | 1192 | def __init__(self, line, linenum, colstart, colend): |
|
1193 | 1193 | self.line = line |
|
1194 | 1194 | self.linenum = linenum |
@@ -1479,7 +1479,7 b' def log(ui, repo, *pats, **opts):' | |||
|
1479 | 1479 | -v switch adds some more detail, such as changed files, manifest |
|
1480 | 1480 | hashes or message signatures. |
|
1481 | 1481 | """ |
|
1482 | class dui: | |
|
1482 | class dui(object): | |
|
1483 | 1483 | # Implement and delegate some ui protocol. Save hunks of |
|
1484 | 1484 | # output for later display in the desired order. |
|
1485 | 1485 | def __init__(self, ui): |
@@ -13,7 +13,7 b' from i18n import gettext as _' | |||
|
13 | 13 | from demandload import * |
|
14 | 14 | demandload(globals(), "time bisect stat util re errno") |
|
15 | 15 | |
|
16 | class dirstate: | |
|
16 | class dirstate(object): | |
|
17 | 17 | def __init__(self, opener, ui, root): |
|
18 | 18 | self.opener = opener |
|
19 | 19 | self.root = root |
@@ -71,7 +71,7 b' def get_mtime(repo_path):' | |||
|
71 | 71 | else: |
|
72 | 72 | return os.stat(hg_path).st_mtime |
|
73 | 73 | |
|
74 | class hgrequest: | |
|
74 | class hgrequest(object): | |
|
75 | 75 | def __init__(self, inp=None, out=None, env=None): |
|
76 | 76 | self.inp = inp or sys.stdin |
|
77 | 77 | self.out = out or sys.stdout |
@@ -104,7 +104,7 b' class hgrequest:' | |||
|
104 | 104 | headers.append(('Content-length', str(size))) |
|
105 | 105 | self.header(headers) |
|
106 | 106 | |
|
107 | class templater: | |
|
107 | class templater(object): | |
|
108 | 108 | def __init__(self, mapfile, filters={}, defaults={}): |
|
109 | 109 | self.cache = {} |
|
110 | 110 | self.map = {} |
@@ -175,7 +175,7 b' common_filters = {' | |||
|
175 | 175 | "rfc822date": lambda x: util.datestr(x, "%a, %d %b %Y %H:%M:%S"), |
|
176 | 176 | } |
|
177 | 177 | |
|
178 | class hgweb: | |
|
178 | class hgweb(object): | |
|
179 | 179 | def __init__(self, repo, name=None): |
|
180 | 180 | if type(repo) == type(""): |
|
181 | 181 | self.repo = hg.repository(ui.ui(), repo) |
@@ -952,7 +952,7 b' def create_server(repo):' | |||
|
952 | 952 | return BaseHTTPServer.HTTPServer((address, port), hgwebhandler) |
|
953 | 953 | |
|
954 | 954 | # This is a stopgap |
|
955 | class hgwebdir: | |
|
955 | class hgwebdir(object): | |
|
956 | 956 | def __init__(self, config): |
|
957 | 957 | def cleannames(items): |
|
958 | 958 | return [(name.strip('/'), path) for name, path in items] |
@@ -7,7 +7,7 b'' | |||
|
7 | 7 | |
|
8 | 8 | import byterange, urllib2 |
|
9 | 9 | |
|
10 | class httprangereader: | |
|
10 | class httprangereader(object): | |
|
11 | 11 | def __init__(self, url): |
|
12 | 12 | self.url = url |
|
13 | 13 | self.pos = 0 |
@@ -12,7 +12,7 b' from i18n import gettext as _' | |||
|
12 | 12 | from demandload import * |
|
13 | 13 | demandload(globals(), "re lock transaction tempfile stat mdiff errno") |
|
14 | 14 | |
|
15 | class localrepository: | |
|
15 | class localrepository(object): | |
|
16 | 16 | def __init__(self, ui, path=None, create=0): |
|
17 | 17 | if not path: |
|
18 | 18 | p = os.getcwd() |
@@ -11,7 +11,7 b' import util' | |||
|
11 | 11 | class LockHeld(Exception): |
|
12 | 12 | pass |
|
13 | 13 | |
|
14 | class lock: | |
|
14 | class lock(object): | |
|
15 | 15 | def __init__(self, file, wait=1, releasefn=None): |
|
16 | 16 | self.f = file |
|
17 | 17 | self.held = 0 |
@@ -5,11 +5,11 b'' | |||
|
5 | 5 | # This software may be used and distributed according to the terms |
|
6 | 6 | # of the GNU General Public License, incorporated herein by reference. |
|
7 | 7 | |
|
8 | class remoterepository: | |
|
8 | class remoterepository(object): | |
|
9 | 9 | def local(self): |
|
10 | 10 | return False |
|
11 | 11 | |
|
12 | class remotelock: | |
|
12 | class remotelock(object): | |
|
13 | 13 | def __init__(self, repo): |
|
14 | 14 | self.repo = repo |
|
15 | 15 | def release(self): |
@@ -52,7 +52,7 b' def decompress(bin):' | |||
|
52 | 52 | |
|
53 | 53 | indexformat = ">4l20s20s20s" |
|
54 | 54 | |
|
55 | class lazyparser: | |
|
55 | class lazyparser(object): | |
|
56 | 56 | """ |
|
57 | 57 | this class avoids the need to parse the entirety of large indices |
|
58 | 58 | |
@@ -94,7 +94,7 b' class lazyparser:' | |||
|
94 | 94 | self.map[e[6]] = i |
|
95 | 95 | i += 1 |
|
96 | 96 | |
|
97 | class lazyindex: | |
|
97 | class lazyindex(object): | |
|
98 | 98 | """a lazy version of the index array""" |
|
99 | 99 | def __init__(self, parser): |
|
100 | 100 | self.p = parser |
@@ -114,7 +114,7 b' class lazyindex:' | |||
|
114 | 114 | def trunc(self, pos): |
|
115 | 115 | self.p.trunc(pos) |
|
116 | 116 | |
|
117 | class lazymap: | |
|
117 | class lazymap(object): | |
|
118 | 118 | """a lazy version of the node map""" |
|
119 | 119 | def __init__(self, parser): |
|
120 | 120 | self.p = parser |
@@ -152,7 +152,7 b' class lazymap:' | |||
|
152 | 152 | |
|
153 | 153 | class RevlogError(Exception): pass |
|
154 | 154 | |
|
155 | class revlog: | |
|
155 | class revlog(object): | |
|
156 | 156 | """ |
|
157 | 157 | the underlying revision storage object |
|
158 | 158 |
General Comments 0
You need to be logged in to leave comments.
Login now