Show More
@@ -1009,15 +1009,34 b' def _getoutgoings(repo, missing, addfunc' | |||
|
1009 | 1009 | |
|
1010 | 1010 | def outgoinghook(ui, repo, other, opts, missing): |
|
1011 | 1011 | if opts.pop('large', None): |
|
1012 |
|
|
|
1013 | lfutil.getlfilestoupload(repo, missing, | |
|
1014 | lambda fn, lfhash: toupload.add(fn)) | |
|
1012 | lfhashes = set() | |
|
1013 | if ui.debugflag: | |
|
1014 | toupload = {} | |
|
1015 | def addfunc(fn, lfhash): | |
|
1016 | if fn not in toupload: | |
|
1017 | toupload[fn] = [] | |
|
1018 | toupload[fn].append(lfhash) | |
|
1019 | lfhashes.add(lfhash) | |
|
1020 | def showhashes(fn): | |
|
1021 | for lfhash in sorted(toupload[fn]): | |
|
1022 | ui.debug(' %s\n' % (lfhash)) | |
|
1023 | else: | |
|
1024 | toupload = set() | |
|
1025 | def addfunc(fn, lfhash): | |
|
1026 | toupload.add(fn) | |
|
1027 | lfhashes.add(lfhash) | |
|
1028 | def showhashes(fn): | |
|
1029 | pass | |
|
1030 | _getoutgoings(repo, missing, addfunc) | |
|
1031 | ||
|
1015 | 1032 | if not toupload: |
|
1016 | 1033 | ui.status(_('largefiles: no files to upload\n')) |
|
1017 | 1034 | else: |
|
1018 |
ui.status(_('largefiles to upload:\n') |
|
|
1035 | ui.status(_('largefiles to upload (%d entities):\n') | |
|
1036 | % (len(lfhashes))) | |
|
1019 | 1037 | for file in sorted(toupload): |
|
1020 | 1038 | ui.status(lfutil.splitstandin(file) + '\n') |
|
1039 | showhashes(file) | |
|
1021 | 1040 | ui.status('\n') |
|
1022 | 1041 | |
|
1023 | 1042 | def summaryremotehook(ui, repo, opts, changes): |
@@ -478,7 +478,7 b' check messages when there are files to u' | |||
|
478 | 478 | date: Thu Jan 01 00:00:00 1970 +0000 |
|
479 | 479 | summary: #1 |
|
480 | 480 | |
|
481 | largefiles to upload: | |
|
481 | largefiles to upload (1 entities): | |
|
482 | 482 | b |
|
483 | 483 | |
|
484 | 484 | $ hg -R clone2 outgoing --large --graph --template "{rev}" |
@@ -486,7 +486,7 b' check messages when there are files to u' | |||
|
486 | 486 | searching for changes |
|
487 | 487 | @ 1 |
|
488 | 488 | |
|
489 | largefiles to upload: | |
|
489 | largefiles to upload (1 entities): | |
|
490 | 490 | b |
|
491 | 491 | |
|
492 | 492 | |
@@ -509,11 +509,28 b' check messages when there are files to u' | |||
|
509 | 509 | searching for changes |
|
510 | 510 | 1:1acbe71ce432 |
|
511 | 511 | 2:6095d0695d70 |
|
512 | largefiles to upload: | |
|
512 | largefiles to upload (1 entities): | |
|
513 | 513 | b |
|
514 | 514 | b1 |
|
515 | 515 | b2 |
|
516 | 516 | |
|
517 | $ hg -R clone2 cat -r 1 clone2/.hglf/b | |
|
518 | 89e6c98d92887913cadf06b2adb97f26cde4849b | |
|
519 | $ hg -R clone2 outgoing --large -T "{rev}:{node|short}\n" --debug | |
|
520 | comparing with $TESTTMP/issue3651/src (glob) | |
|
521 | query 1; heads | |
|
522 | searching for changes | |
|
523 | all remote heads known locally | |
|
524 | 1:1acbe71ce432 | |
|
525 | 2:6095d0695d70 | |
|
526 | largefiles to upload (1 entities): | |
|
527 | b | |
|
528 | 89e6c98d92887913cadf06b2adb97f26cde4849b | |
|
529 | b1 | |
|
530 | 89e6c98d92887913cadf06b2adb97f26cde4849b | |
|
531 | b2 | |
|
532 | 89e6c98d92887913cadf06b2adb97f26cde4849b | |
|
533 | ||
|
517 | 534 | |
|
518 | 535 | $ echo bbb > clone2/b |
|
519 | 536 | $ hg -R clone2 commit -m '#3: add new largefile entity as existing file' |
@@ -542,11 +559,35 b' check messages when there are files to u' | |||
|
542 | 559 | 3:7983dce246cc |
|
543 | 560 | 4:233f12ada4ae |
|
544 | 561 | 5:036794ea641c |
|
545 | largefiles to upload: | |
|
562 | largefiles to upload (3 entities): | |
|
546 | 563 | b |
|
547 | 564 | b1 |
|
548 | 565 | b2 |
|
549 | 566 | |
|
567 | $ hg -R clone2 cat -r 3 clone2/.hglf/b | |
|
568 | c801c9cfe94400963fcb683246217d5db77f9a9a | |
|
569 | $ hg -R clone2 cat -r 4 clone2/.hglf/b | |
|
570 | 13f9ed0898e315bf59dc2973fec52037b6f441a2 | |
|
571 | $ hg -R clone2 outgoing --large -T "{rev}:{node|short}\n" --debug | |
|
572 | comparing with $TESTTMP/issue3651/src (glob) | |
|
573 | query 1; heads | |
|
574 | searching for changes | |
|
575 | all remote heads known locally | |
|
576 | 1:1acbe71ce432 | |
|
577 | 2:6095d0695d70 | |
|
578 | 3:7983dce246cc | |
|
579 | 4:233f12ada4ae | |
|
580 | 5:036794ea641c | |
|
581 | largefiles to upload (3 entities): | |
|
582 | b | |
|
583 | 13f9ed0898e315bf59dc2973fec52037b6f441a2 | |
|
584 | 89e6c98d92887913cadf06b2adb97f26cde4849b | |
|
585 | c801c9cfe94400963fcb683246217d5db77f9a9a | |
|
586 | b1 | |
|
587 | 89e6c98d92887913cadf06b2adb97f26cde4849b | |
|
588 | b2 | |
|
589 | 89e6c98d92887913cadf06b2adb97f26cde4849b | |
|
590 | ||
|
550 | 591 | |
|
551 | 592 | $ cd .. |
|
552 | 593 |
General Comments 0
You need to be logged in to leave comments.
Login now