summaryrefslogtreecommitdiff
path: root/builtin/pack-redundant.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2021-01-25 22:19:17 (GMT)
committerJunio C Hamano <gitster@pobox.com>2021-01-25 22:19:18 (GMT)
commitdfcd90506998c1de8d8ef86431c86ef9ed626c30 (patch)
tree8bcb3da106401aedd656684e4acb6d7eead26ab5 /builtin/pack-redundant.c
parentc7b1aaf6d6bb5746a98831854313ca8fccea600d (diff)
parentc3b58472be2c647cd0c5af328980b15bd3f43b69 (diff)
downloadgit-dfcd90506998c1de8d8ef86431c86ef9ed626c30.zip
git-dfcd90506998c1de8d8ef86431c86ef9ed626c30.tar.gz
git-dfcd90506998c1de8d8ef86431c86ef9ed626c30.tar.bz2
Merge branch 'jc/deprecate-pack-redundant'
Warn loudly when the "pack-redundant" command, which has been left stale with almost unusable performance issues, gets used, as we no longer want to recommend its use (instead just "repack -d" instead). * jc/deprecate-pack-redundant: pack-redundant: gauge the usage before proposing its removal
Diffstat (limited to 'builtin/pack-redundant.c')
-rw-r--r--builtin/pack-redundant.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/builtin/pack-redundant.c b/builtin/pack-redundant.c
index 9fcea3e..6e115a8 100644
--- a/builtin/pack-redundant.c
+++ b/builtin/pack-redundant.c
@@ -560,6 +560,7 @@ static void load_all(void)
int cmd_pack_redundant(int argc, const char **argv, const char *prefix)
{
int i;
+ int i_still_use_this = 0;
struct pack_list *min = NULL, *red, *pl;
struct llist *ignore;
struct object_id *oid;
@@ -586,12 +587,24 @@ int cmd_pack_redundant(int argc, const char **argv, const char *prefix)
alt_odb = 1;
continue;
}
+ if (!strcmp(arg, "--i-still-use-this")) {
+ i_still_use_this = 1;
+ continue;
+ }
if (*arg == '-')
usage(pack_redundant_usage);
else
break;
}
+ if (!i_still_use_this) {
+ fputs(_("'git pack-redundant' is nominated for removal.\n"
+ "If you still use this command, please add an extra\n"
+ "option, '--i-still-use-this', on the command line\n"
+ "and let us know you still use it by sending an e-mail\n"
+ "to <git@vger.kernel.org>. Thanks.\n"), stderr);
+ }
+
if (load_all_packs)
load_all();
else