Show More
@@ -1359,11 +1359,12 class queue(object): | |||||
1359 |
|
1359 | |||
1360 | tobackup = set() |
|
1360 | tobackup = set() | |
1361 | if (not nobackup and force) or keepchanges: |
|
1361 | if (not nobackup and force) or keepchanges: | |
1362 |
|
|
1362 | status = self.checklocalchanges(repo, force=True) | |
1363 | if keepchanges: |
|
1363 | if keepchanges: | |
1364 |
tobackup.update(m + a + |
|
1364 | tobackup.update(status.modified + status.added + | |
|
1365 | status.removed + status.deleted) | |||
1365 | else: |
|
1366 | else: | |
1366 | tobackup.update(m + a) |
|
1367 | tobackup.update(status.modified + status.added) | |
1367 |
|
1368 | |||
1368 | s = self.series[start:end] |
|
1369 | s = self.series[start:end] | |
1369 | all_files = set() |
|
1370 | all_files = set() | |
@@ -1447,13 +1448,13 class queue(object): | |||||
1447 |
|
1448 | |||
1448 | tobackup = set() |
|
1449 | tobackup = set() | |
1449 | if update: |
|
1450 | if update: | |
1450 |
|
|
1451 | s = self.checklocalchanges(repo, force=force or keepchanges) | |
1451 | repo, force=force or keepchanges) |
|
|||
1452 | if force: |
|
1452 | if force: | |
1453 | if not nobackup: |
|
1453 | if not nobackup: | |
1454 | tobackup.update(m + a) |
|
1454 | tobackup.update(s.modified + s.added) | |
1455 | elif keepchanges: |
|
1455 | elif keepchanges: | |
1456 |
tobackup.update(m + a + |
|
1456 | tobackup.update(s.modified + s.added + | |
|
1457 | s.removed + s.deleted) | |||
1457 |
|
1458 | |||
1458 | self.applieddirty = True |
|
1459 | self.applieddirty = True | |
1459 | end = len(self.applied) |
|
1460 | end = len(self.applied) |
@@ -32,15 +32,15 def checksubstate(repo, baserev=None): | |||||
32 |
|
32 | |||
33 | def checklocalchanges(repo, force=False, excsuffix=''): |
|
33 | def checklocalchanges(repo, force=False, excsuffix=''): | |
34 | cmdutil.checkunfinished(repo) |
|
34 | cmdutil.checkunfinished(repo) | |
35 |
|
|
35 | s = repo.status() | |
36 | if not force: |
|
36 | if not force: | |
37 |
if |
|
37 | if s.modified or s.added or s.removed or s.deleted: | |
38 | _("local changes found") # i18n tool detection |
|
38 | _("local changes found") # i18n tool detection | |
39 | raise util.Abort(_("local changes found" + excsuffix)) |
|
39 | raise util.Abort(_("local changes found" + excsuffix)) | |
40 | if checksubstate(repo): |
|
40 | if checksubstate(repo): | |
41 | _("local changed subrepos found") # i18n tool detection |
|
41 | _("local changed subrepos found") # i18n tool detection | |
42 | raise util.Abort(_("local changed subrepos found" + excsuffix)) |
|
42 | raise util.Abort(_("local changed subrepos found" + excsuffix)) | |
43 |
return |
|
43 | return s | |
44 |
|
44 | |||
45 | def strip(ui, repo, revs, update=True, backup=True, force=None, bookmark=None): |
|
45 | def strip(ui, repo, revs, update=True, backup=True, force=None, bookmark=None): | |
46 | wlock = lock = None |
|
46 | wlock = lock = None |
General Comments 0
You need to be logged in to leave comments.
Login now