##// END OF EJS Templates
scmutil: add join method to opener to construct path relative to base...
Idan Kamara -
r16199:8181bd80 stable
parent child Browse files
Show More
@@ -211,7 +211,7 b' class opener(abstractopener):'
211 211 if r:
212 212 raise util.Abort("%s: %r" % (r, path))
213 213 self.auditor(path)
214 f = os.path.join(self.base, path)
214 f = self.join(path)
215 215
216 216 if not text and "b" not in mode:
217 217 mode += "b" # for that other OS
@@ -255,7 +255,7 b' class opener(abstractopener):'
255 255
256 256 def symlink(self, src, dst):
257 257 self.auditor(dst)
258 linkname = os.path.join(self.base, dst)
258 linkname = self.join(dst)
259 259 try:
260 260 os.unlink(linkname)
261 261 except OSError:
@@ -280,6 +280,9 b' class opener(abstractopener):'
280 280 def audit(self, path):
281 281 self.auditor(path)
282 282
283 def join(self, path):
284 return os.path.join(self.base, path)
285
283 286 class filteropener(abstractopener):
284 287 '''Wrapper opener for filtering filenames with a function.'''
285 288
General Comments 0
You need to be logged in to leave comments. Login now