Show More
@@ -282,23 +282,14 b' class localrepository(object):' | |||||
282 |
|
282 | |||
283 | if not self.vfs.isdir(): |
|
283 | if not self.vfs.isdir(): | |
284 | if create: |
|
284 | if create: | |
285 | if not self.wvfs.exists(): |
|
|||
286 | self.wvfs.makedirs() |
|
|||
287 | self.vfs.makedir(notindexed=True) |
|
|||
288 | requirements = set(self._baserequirements(create)) |
|
285 | requirements = set(self._baserequirements(create)) | |
289 | if self.ui.configbool('format', 'usestore', True): |
|
286 | if self.ui.configbool('format', 'usestore', True): | |
290 | self.vfs.mkdir("store") |
|
|||
291 | requirements.add("store") |
|
287 | requirements.add("store") | |
292 | if self.ui.configbool('format', 'usefncache', True): |
|
288 | if self.ui.configbool('format', 'usefncache', True): | |
293 | requirements.add("fncache") |
|
289 | requirements.add("fncache") | |
294 | if self.ui.configbool('format', 'dotencode', True): |
|
290 | if self.ui.configbool('format', 'dotencode', True): | |
295 | requirements.add('dotencode') |
|
291 | requirements.add('dotencode') | |
296 | # create an invalid changelog |
|
292 | ||
297 | self.vfs.append( |
|
|||
298 | "00changelog.i", |
|
|||
299 | '\0\0\0\2' # represents revlogv2 |
|
|||
300 | ' dummy changelog to prevent using the old repo layout' |
|
|||
301 | ) |
|
|||
302 | if scmutil.gdinitconfig(self.ui): |
|
293 | if scmutil.gdinitconfig(self.ui): | |
303 | requirements.add("generaldelta") |
|
294 | requirements.add("generaldelta") | |
304 | if self.ui.configbool('experimental', 'treemanifest', False): |
|
295 | if self.ui.configbool('experimental', 'treemanifest', False): | |
@@ -307,6 +298,20 b' class localrepository(object):' | |||||
307 | requirements.add("manifestv2") |
|
298 | requirements.add("manifestv2") | |
308 |
|
299 | |||
309 | self.requirements = requirements |
|
300 | self.requirements = requirements | |
|
301 | ||||
|
302 | if not self.wvfs.exists(): | |||
|
303 | self.wvfs.makedirs() | |||
|
304 | self.vfs.makedir(notindexed=True) | |||
|
305 | ||||
|
306 | if 'store' in requirements: | |||
|
307 | self.vfs.mkdir("store") | |||
|
308 | ||||
|
309 | # create an invalid changelog | |||
|
310 | self.vfs.append( | |||
|
311 | "00changelog.i", | |||
|
312 | '\0\0\0\2' # represents revlogv2 | |||
|
313 | ' dummy changelog to prevent using the old repo layout' | |||
|
314 | ) | |||
310 | else: |
|
315 | else: | |
311 | raise error.RepoError(_("repository %s not found") % path) |
|
316 | raise error.RepoError(_("repository %s not found") % path) | |
312 | elif create: |
|
317 | elif create: |
General Comments 0
You need to be logged in to leave comments.
Login now