aboutsummaryrefslogtreecommitdiffstats
path: root/builtin/index-pack.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2025-07-17 09:30:56 -0700
committerJunio C Hamano <gitster@pobox.com>2025-07-17 09:30:56 -0700
commit86c9c14eb9c7bfa20efd8d65f1aaa685282b7221 (patch)
treefd758d24e1db2726312822e7f8e5d1ffcdd13444 /builtin/index-pack.c
parentThe eleventh batch (diff)
parentEnable SHA-256 by default in breaking changes mode (diff)
downloadgit-86c9c14eb9c7bfa20efd8d65f1aaa685282b7221.tar.gz
git-86c9c14eb9c7bfa20efd8d65f1aaa685282b7221.zip
Merge branch 'bc/use-sha256-by-default-in-3.0' into ps/config-wo-the-repository
* bc/use-sha256-by-default-in-3.0: Enable SHA-256 by default in breaking changes mode help: add a build option for default hash t5300: choose the built-in hash outside of a repo t4042: choose the built-in hash outside of a repo t1007: choose the built-in hash outside of a repo t: default to compile-time default hash if not set setup: use the default algorithm to initialize repo format Use legacy hash for legacy formats builtin: use default hash when outside a repository hash: add a constant for the legacy hash algorithm hash: add a constant for the default hash algorithm
Diffstat (limited to 'builtin/index-pack.c')
-rw-r--r--builtin/index-pack.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/index-pack.c b/builtin/index-pack.c
index 19c67a8534..0a5c8a1ac8 100644
--- a/builtin/index-pack.c
+++ b/builtin/index-pack.c
@@ -2035,7 +2035,7 @@ int cmd_index_pack(int argc,
* choice but to guess the object hash.
*/
if (!the_repository->hash_algo)
- repo_set_hash_algo(the_repository, GIT_HASH_SHA1);
+ repo_set_hash_algo(the_repository, GIT_HASH_DEFAULT);
opts.flags &= ~(WRITE_REV | WRITE_REV_VERIFY);
if (rev_index) {