Mercurial > public > mercurial-scm > hg
comparison mercurial/scmutil.py @ 17726:7cb7e17c23b2
store: invoke "os.stat()" for "createmode" initialization via vfs
This just replaces "os.stat()" invocation: refactoring around
"self.createmode" and "vfs.createmode" initialization is omitted.
This patch also newly adds "stat()" function to "abstractvfs".
author | FUJIWARA Katsunori <foozy@lares.dti.ne.jp> |
---|---|
date | Tue, 09 Oct 2012 01:41:55 +0900 |
parents | ffd589d4b785 |
children | aad3bce98f76 |
comparison
equal
deleted
inserted
replaced
17725:ffd589d4b785 | 17726:7cb7e17c23b2 |
---|---|
216 def makedirs(self, path=None, mode=None): | 216 def makedirs(self, path=None, mode=None): |
217 return util.makedirs(self.join(path), mode) | 217 return util.makedirs(self.join(path), mode) |
218 | 218 |
219 def mkdir(self, path=None): | 219 def mkdir(self, path=None): |
220 return os.mkdir(self.join(path)) | 220 return os.mkdir(self.join(path)) |
221 | |
222 def stat(self, path=None): | |
223 return os.stat(self.join(path)) | |
221 | 224 |
222 class vfs(abstractvfs): | 225 class vfs(abstractvfs): |
223 '''Operate files relative to a base directory | 226 '''Operate files relative to a base directory |
224 | 227 |
225 This class is used to hide the details of COW semantics and | 228 This class is used to hide the details of COW semantics and |