comparison hgext/convert/subversion.py @ 5956:094638b3cbed

convert: checkout svn root revisions Using changed files is enough if whole history is converted. Checkouts are required to restrict the conversion to user-supplied subtree.
author Patrick Mezard <pmezard@gmail.com>
date Sat, 26 Jan 2008 14:45:04 +0100
parents c4496b7c10ce
children 971a17af5982
comparison
equal deleted inserted replaced
5955:c4496b7c10ce 5956:094638b3cbed
284 if self._changescache and self._changescache[0] == rev: 284 if self._changescache and self._changescache[0] == rev:
285 return self._changescache[1] 285 return self._changescache[1]
286 self._changescache = None 286 self._changescache = None
287 self.modecache = {} 287 self.modecache = {}
288 (paths, parents) = self.paths[rev] 288 (paths, parents) = self.paths[rev]
289 files, copies = self.expandpaths(rev, paths, parents) 289 if parents:
290 files, copies = self.expandpaths(rev, paths, parents)
291 else:
292 # Perform a full checkout on roots
293 uuid, module, revnum = self.revsplit(rev)
294 entries = svn.client.ls(self.base + module, optrev(revnum),
295 True, self.ctx)
296 files = [n for n,e in entries.iteritems()
297 if e.kind == svn.core.svn_node_file]
298 copies = {}
299
290 files.sort() 300 files.sort()
291 files = zip(files, [rev] * len(files)) 301 files = zip(files, [rev] * len(files))
292 302
293 # caller caches the result, so free it here to release memory 303 # caller caches the result, so free it here to release memory
294 del self.paths[rev] 304 del self.paths[rev]