largefiles: don't assume that .hg/largefiles/ still exists stable
authorMads Kiilerich <madski@unity3d.com>
Thu, 28 Feb 2013 13:45:18 +0100
branchstable
changeset 18725 0ac00315875f
parent 18724 894a5897a9dd
child 18726 431b246cfb12
largefiles: don't assume that .hg/largefiles/ still exists It might not have been created and it might have been removed.
hgext/largefiles/basestore.py
tests/test-largefiles-cache.t
--- a/hgext/largefiles/basestore.py	Thu Feb 28 13:45:18 2013 +0100
+++ b/hgext/largefiles/basestore.py	Thu Feb 28 13:45:18 2013 +0100
@@ -59,6 +59,8 @@
         missing = []
         ui = self.ui
 
+        util.makedirs(lfutil.storepath(self.repo, ''))
+
         at = 0
         for filename, hash in files:
             ui.progress(_('getting largefiles'), at, unit='lfile',
--- a/tests/test-largefiles-cache.t	Thu Feb 28 13:45:18 2013 +0100
+++ b/tests/test-largefiles-cache.t	Thu Feb 28 13:45:18 2013 +0100
@@ -84,8 +84,7 @@
   added 1 changesets with 1 changes to 1 files
   (run 'hg update' to get a working copy)
   caching new largefiles
-  abort: *: '$TESTTMP/mirror2/.hg/largefiles/.7f7097b041ccf68cc5561e9600da4655d21c6d18.*' (glob)
-  [255]
+  1 largefiles cached
 
 #if unix-permissions