Show More
@@ -505,9 +505,9 b' class queue:' | |||
|
505 | 505 | # we go in two steps here so the strip loop happens in a |
|
506 | 506 | # sensible order. When stripping many files, this helps keep |
|
507 | 507 | # our disk access patterns under control. |
|
508 | list = seen.keys() | |
|
509 | list.sort() | |
|
510 | for f in list: | |
|
508 | seen_list = seen.keys() | |
|
509 | seen_list.sort() | |
|
510 | for f in seen_list: | |
|
511 | 511 | ff = repo.file(f) |
|
512 | 512 | filerev = seen[f] |
|
513 | 513 | if filerev != 0: |
@@ -944,7 +944,7 b' class queue:' | |||
|
944 | 944 | msg = '' |
|
945 | 945 | self.ui.write('%s%s\n' % (patch, msg)) |
|
946 | 946 | else: |
|
947 | list = [] | |
|
947 | msng_list = [] | |
|
948 | 948 | for root, dirs, files in os.walk(self.path): |
|
949 | 949 | d = root[len(self.path) + 1:] |
|
950 | 950 | for f in files: |
@@ -952,10 +952,10 b' class queue:' | |||
|
952 | 952 | if (fl not in self.series and |
|
953 | 953 | fl not in (self.status_path, self.series_path) |
|
954 | 954 | and not fl.startswith('.')): |
|
955 | list.append(fl) | |
|
956 | list.sort() | |
|
957 | if list: | |
|
958 | for x in list: | |
|
955 | msng_list.append(fl) | |
|
956 | msng_list.sort() | |
|
957 | if msng_list: | |
|
958 | for x in msng_list: | |
|
959 | 959 | if self.ui.verbose: |
|
960 | 960 | self.ui.write("D ") |
|
961 | 961 | self.ui.write("%s\n" % x) |
@@ -988,11 +988,10 b' class queue:' | |||
|
988 | 988 | elif datastart != None: |
|
989 | 989 | l = lines[i].rstrip() |
|
990 | 990 | se = StatusEntry(l) |
|
991 |
|
|
|
992 |
|
|
|
993 | if id: | |
|
991 | file_ = se.name | |
|
992 | if se.rev: | |
|
994 | 993 | applied.append(se) |
|
995 | series.append(file) | |
|
994 | series.append(file_) | |
|
996 | 995 | if datastart == None: |
|
997 | 996 | self.ui.warn("No saved patch data found\n") |
|
998 | 997 | return 1 |
@@ -1389,20 +1388,20 b' def header(ui, repo, patch=None):' | |||
|
1389 | 1388 | ui.write('\n'.join(message) + '\n') |
|
1390 | 1389 | |
|
1391 | 1390 | def lastsavename(path): |
|
1392 | (dir, base) = os.path.split(path) | |
|
1393 | names = os.listdir(dir) | |
|
1391 | (directory, base) = os.path.split(path) | |
|
1392 | names = os.listdir(directory) | |
|
1394 | 1393 | namere = re.compile("%s.([0-9]+)" % base) |
|
1395 | max = None | |
|
1394 | maxindex = None | |
|
1396 | 1395 | maxname = None |
|
1397 | 1396 | for f in names: |
|
1398 | 1397 | m = namere.match(f) |
|
1399 | 1398 | if m: |
|
1400 | 1399 | index = int(m.group(1)) |
|
1401 | if max == None or index > max: | |
|
1402 | max = index | |
|
1400 | if maxindex == None or index > maxindex: | |
|
1401 | maxindex = index | |
|
1403 | 1402 | maxname = f |
|
1404 | 1403 | if maxname: |
|
1405 | return (os.path.join(dir, maxname), max) | |
|
1404 | return (os.path.join(directory, maxname), maxindex) | |
|
1406 | 1405 | return (None, None) |
|
1407 | 1406 | |
|
1408 | 1407 | def savename(path): |
General Comments 0
You need to be logged in to leave comments.
Login now