Show More
@@ -160,6 +160,16 b' def pullbundle2extraprepare(orig, pullop' | |||
|
160 | 160 | extensions.wrapfunction(exchange,'_pullbundle2extraprepare', |
|
161 | 161 | pullbundle2extraprepare) |
|
162 | 162 | |
|
163 | # This is an extension point for filesystems that need to do something other | |
|
164 | # than just blindly unlink the files. It's not clear what arguments would be | |
|
165 | # useful, so we're passing in a fair number of them, some of them redundant. | |
|
166 | def _narrowcleanupwdir(repo, oldincludes, oldexcludes, newincludes, newexcludes, | |
|
167 | oldmatch, newmatch): | |
|
168 | for f in repo.dirstate: | |
|
169 | if not newmatch(f): | |
|
170 | repo.dirstate.drop(f) | |
|
171 | repo.wvfs.unlinkpath(f) | |
|
172 | ||
|
163 | 173 | def _narrow(ui, repo, remote, commoninc, oldincludes, oldexcludes, |
|
164 | 174 | newincludes, newexcludes, force): |
|
165 | 175 | oldmatch = narrowspec.match(repo.root, oldincludes, oldexcludes) |
@@ -235,10 +245,8 b' def _narrow(ui, repo, remote, commoninc,' | |||
|
235 | 245 | util.unlinkpath(repo.svfs.join(f)) |
|
236 | 246 | repo.store.markremoved(f) |
|
237 | 247 | |
|
238 | for f in repo.dirstate: | |
|
239 |
|
|
|
240 | repo.dirstate.drop(f) | |
|
241 | repo.wvfs.unlinkpath(f) | |
|
248 | _narrowcleanupwdir(repo, oldincludes, oldexcludes, newincludes, | |
|
249 | newexcludes, oldmatch, newmatch) | |
|
242 | 250 | repo.setnarrowpats(newincludes, newexcludes) |
|
243 | 251 | |
|
244 | 252 | repo.destroyed() |
General Comments 0
You need to be logged in to leave comments.
Login now