Mercurial > hg-stable
changeset 17160:22b9b1d2f5d4
localrepo: use "vfs" intead of "opener" while ensuring repository directory
As a part of migration to vfs, this patch uses "self.vfs" instead of
"self.opener", while ensuring repository directory in the constructor
of "localrepository" class.
author | FUJIWARA Katsunori <foozy@lares.dti.ne.jp> |
---|---|
date | Fri, 06 Jul 2012 18:45:27 +0900 |
parents | 36a3016811d1 |
children | be016e96117a |
files | mercurial/localrepo.py |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/localrepo.py Fri Jul 06 18:45:27 2012 +0900 +++ b/mercurial/localrepo.py Fri Jul 06 18:45:27 2012 +0900 @@ -72,7 +72,7 @@ if self.ui.configbool('format', 'dotencode', True): requirements.append('dotencode') # create an invalid changelog - self.opener.append( + self.vfs.append( "00changelog.i", '\0\0\0\2' # represents revlogv2 ' dummy changelog to prevent using the old repo layout' @@ -86,7 +86,7 @@ raise error.RepoError(_("repository %s already exists") % path) else: try: - requirements = scmutil.readrequires(self.opener, self.supported) + requirements = scmutil.readrequires(self.vfs, self.supported) except IOError, inst: if inst.errno != errno.ENOENT: raise