Show More
@@ -2330,10 +2330,14 b' def revert(ui, repo, ctx, parents, *pats' | |||||
2330 | # action if not in target manifest |
|
2330 | # action if not in target manifest | |
2331 | # make backup if in target manifest |
|
2331 | # make backup if in target manifest | |
2332 | # make backup if not in target manifest |
|
2332 | # make backup if not in target manifest | |
2333 |
(modified, actions['revert'], |
|
2333 | (modified, (actions['revert'], True), | |
2334 | (added, actions['revert'], actions['remove'], True, False), |
|
2334 | (actions['remove'], True)), | |
2335 |
( |
|
2335 | (added, (actions['revert'], True), | |
2336 |
( |
|
2336 | (actions['remove'], False)), | |
|
2337 | (removed, (actions['undelete'], True), | |||
|
2338 | (None, False)), | |||
|
2339 | (deleted, (actions['revert'], False), | |||
|
2340 | (actions['remove'], False)), | |||
2337 | ) |
|
2341 | ) | |
2338 |
|
2342 | |||
2339 | for abs, (rel, exact) in sorted(names.items()): |
|
2343 | for abs, (rel, exact) in sorted(names.items()): | |
@@ -2359,14 +2363,14 b' def revert(ui, repo, ctx, parents, *pats' | |||||
2359 | # search the entry in the dispatch table. |
|
2363 | # search the entry in the dispatch table. | |
2360 | # if the file is in any of this sets, it was touched in the working |
|
2364 | # if the file is in any of this sets, it was touched in the working | |
2361 | # directory parent and we are sure it needs to be reverted. |
|
2365 | # directory parent and we are sure it needs to be reverted. | |
2362 |
for table, hit |
|
2366 | for table, hit, miss in disptable: | |
2363 | if abs not in table: |
|
2367 | if abs not in table: | |
2364 | continue |
|
2368 | continue | |
2365 | # file has changed in dirstate |
|
2369 | # file has changed in dirstate | |
2366 | if mfentry: |
|
2370 | if mfentry: | |
2367 |
handle( |
|
2371 | handle(*hit) | |
2368 |
elif miss |
|
2372 | elif miss[0] is not None: | |
2369 |
handle( |
|
2373 | handle(*miss) | |
2370 | break |
|
2374 | break | |
2371 | else: |
|
2375 | else: | |
2372 | # Not touched in current dirstate. |
|
2376 | # Not touched in current dirstate. |
General Comments 0
You need to be logged in to leave comments.
Login now