Show More
@@ -63,6 +63,13 command = registrar.command(cmdtable) | |||
|
63 | 63 | # leave the attribute unspecified. |
|
64 | 64 | testedwith = 'ships-with-hg-core' |
|
65 | 65 | |
|
66 | configtable = {} | |
|
67 | configitem = registrar.configitem(configtable) | |
|
68 | ||
|
69 | configitem('shelve', 'maxbackups', | |
|
70 | default=10, | |
|
71 | ) | |
|
72 | ||
|
66 | 73 | backupdir = 'shelve-backup' |
|
67 | 74 | shelvedir = 'shelved' |
|
68 | 75 | shelvefileextensions = ['hg', 'patch', 'oshelve'] |
@@ -271,7 +278,7 class shelvedstate(object): | |||
|
271 | 278 | |
|
272 | 279 | def cleanupoldbackups(repo): |
|
273 | 280 | vfs = vfsmod.vfs(repo.vfs.join(backupdir)) |
|
274 |
maxbackups = repo.ui.configint('shelve', 'maxbackups' |
|
|
281 | maxbackups = repo.ui.configint('shelve', 'maxbackups') | |
|
275 | 282 | hgfiles = [f for f in vfs.listdir() |
|
276 | 283 | if f.endswith('.' + patchextension)] |
|
277 | 284 | hgfiles = sorted([(vfs.stat(f).st_mtime, f) for f in hgfiles]) |
General Comments 0
You need to be logged in to leave comments.
Login now