| 370 | } |
| 371 | |
| 372 | static int cmd_multi_pack_index_repack(int argc, const char **argv, |
| 373 | const char *prefix, |
| 374 | struct repository *repo UNUSED) |
| 375 | { |
| 376 | struct option *options; |
| 377 | static struct option builtin_multi_pack_index_repack_options[] = { |
| 378 | OPT_UNSIGNED(0, "batch-size", &opts.batch_size, |
| 379 | N_("during repack, collect pack-files of smaller size into a batch that is larger than this size")), |
| 380 | OPT_END(), |
| 381 | }; |
| 382 | struct odb_source *source; |
| 383 | |
| 384 | options = add_common_options(builtin_multi_pack_index_repack_options); |
| 385 | |
| 386 | trace2_cmd_mode(argv[0]); |
| 387 | |
| 388 | if (isatty(2)) |
| 389 | opts.flags |= MIDX_PROGRESS; |
| 390 | argc = parse_options(argc, argv, prefix, |
| 391 | options, |
| 392 | builtin_multi_pack_index_repack_usage, |
| 393 | 0); |
| 394 | if (argc) |
| 395 | usage_with_options(builtin_multi_pack_index_repack_usage, |
| 396 | options); |
| 397 | source = handle_object_dir_option(the_repository); |
| 398 | |
| 399 | FREE_AND_NULL(options); |
| 400 | |
| 401 | return midx_repack(source, (size_t)opts.batch_size, opts.flags); |
| 402 | } |
| 403 | |
| 404 | int cmd_multi_pack_index(int argc, |
| 405 | const char **argv, |
nothing calls this directly
no test coverage detected