Show More
@@ -872,6 +872,11 b' def supportedoutgoingversions(repo):' | |||||
872 | versions.discard('02') |
|
872 | versions.discard('02') | |
873 | return versions |
|
873 | return versions | |
874 |
|
874 | |||
|
875 | def localversion(repo): | |||
|
876 | # Finds the best version to use for bundles that are meant to be used | |||
|
877 | # locally, such as those from strip and shelve, and temporary bundles. | |||
|
878 | return max(supportedoutgoingversions(repo)) | |||
|
879 | ||||
875 | def safeversion(repo): |
|
880 | def safeversion(repo): | |
876 | # Finds the smallest version that it's safe to assume clients of the repo |
|
881 | # Finds the smallest version that it's safe to assume clients of the repo | |
877 | # will support. For example, all hg versions that support generaldelta also |
|
882 | # will support. For example, all hg versions that support generaldelta also |
@@ -38,7 +38,7 b' def _bundle(repo, bases, heads, node, su' | |||||
38 | totalhash = hashlib.sha1(''.join(allhashes)).hexdigest() |
|
38 | totalhash = hashlib.sha1(''.join(allhashes)).hexdigest() | |
39 | name = "%s/%s-%s-%s.hg" % (backupdir, short(node), totalhash[:8], suffix) |
|
39 | name = "%s/%s-%s-%s.hg" % (backupdir, short(node), totalhash[:8], suffix) | |
40 |
|
40 | |||
41 |
cgversion = changegroup. |
|
41 | cgversion = changegroup.localversion(repo) | |
42 | comp = None |
|
42 | comp = None | |
43 | if cgversion != '01': |
|
43 | if cgversion != '01': | |
44 | bundletype = "HG20" |
|
44 | bundletype = "HG20" |
@@ -399,11 +399,10 b" Check that temporary bundle doesn't lose" | |||||
399 | $ hg rebase -s 1 -d 2 |
|
399 | $ hg rebase -s 1 -d 2 | |
400 | rebasing 1:d2ae7f538514 "b" |
|
400 | rebasing 1:d2ae7f538514 "b" | |
401 | saved backup bundle to $TESTTMP/issue5678/.hg/strip-backup/d2ae7f538514-2953539b-rebase.hg (glob) |
|
401 | saved backup bundle to $TESTTMP/issue5678/.hg/strip-backup/d2ae7f538514-2953539b-rebase.hg (glob) | |
402 | BROKEN: d36c should remain public |
|
|||
403 | $ hg log -G -T '{rev}:{node|shortest} {phase} {desc}\n' |
|
402 | $ hg log -G -T '{rev}:{node|shortest} {phase} {desc}\n' | |
404 | o 2:c882 draft b |
|
403 | o 2:c882 draft b | |
405 | | |
|
404 | | | |
406 |
@ 1:d36c |
|
405 | @ 1:d36c public c | |
407 | | |
|
406 | | | |
408 | o 0:cb9a public a |
|
407 | o 0:cb9a public a | |
409 |
|
408 |
@@ -1116,6 +1116,6 b' Test that obsmarkers are restored even w' | |||||
1116 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
1116 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
1117 | saved backup bundle to $TESTTMP/issue5678/.hg/strip-backup/489bac576828-bef27e14-backup.hg (glob) |
|
1117 | saved backup bundle to $TESTTMP/issue5678/.hg/strip-backup/489bac576828-bef27e14-backup.hg (glob) | |
1118 | $ hg unbundle -q .hg/strip-backup/* |
|
1118 | $ hg unbundle -q .hg/strip-backup/* | |
1119 | BROKEN: obsmarker got lost |
|
|||
1120 | $ hg debugobsolete |
|
1119 | $ hg debugobsolete | |
|
1120 | cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b 489bac576828490c0bb8d45eac9e5e172e4ec0a8 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |||
1121 | $ cd .. |
|
1121 | $ cd .. |
General Comments 0
You need to be logged in to leave comments.
Login now