equal
deleted
inserted
replaced
259 def copyalltostore(repo, node): |
259 def copyalltostore(repo, node): |
260 '''Copy all largefiles in a given revision to the store''' |
260 '''Copy all largefiles in a given revision to the store''' |
261 |
261 |
262 ctx = repo[node] |
262 ctx = repo[node] |
263 for filename in ctx.files(): |
263 for filename in ctx.files(): |
264 if isstandin(filename) and filename in ctx.manifest(): |
264 realfile = splitstandin(filename) |
265 realfile = splitstandin(filename) |
265 if realfile is not None and filename in ctx.manifest(): |
266 copytostore(repo, ctx.node(), realfile) |
266 copytostore(repo, ctx.node(), realfile) |
267 |
267 |
268 def copytostoreabsolute(repo, file, hash): |
268 def copytostoreabsolute(repo, file, hash): |
269 if inusercache(repo.ui, hash): |
269 if inusercache(repo.ui, hash): |
270 link(usercachepath(repo.ui, hash), storepath(repo, hash)) |
270 link(usercachepath(repo.ui, hash), storepath(repo, hash)) |
476 # - have to be marked as "n" after commit, but |
476 # - have to be marked as "n" after commit, but |
477 # - aren't listed in "repo[node].files()" |
477 # - aren't listed in "repo[node].files()" |
478 |
478 |
479 lfdirstate = openlfdirstate(repo.ui, repo) |
479 lfdirstate = openlfdirstate(repo.ui, repo) |
480 for f in ctx.files(): |
480 for f in ctx.files(): |
481 if isstandin(f): |
481 lfile = splitstandin(f) |
482 lfile = splitstandin(f) |
482 if lfile is not None: |
483 synclfdirstate(repo, lfdirstate, lfile, False) |
483 synclfdirstate(repo, lfdirstate, lfile, False) |
484 lfdirstate.write() |
484 lfdirstate.write() |
485 |
485 |
486 # As part of committing, copy all of the largefiles into the cache. |
486 # As part of committing, copy all of the largefiles into the cache. |
487 copyalltostore(repo, node) |
487 copyalltostore(repo, node) |