refs: make refs/bisect/* per-worktree
We need the place we stick refs for bisects in progress to not be shared between worktrees. So we make the refs/bisect/ hierarchy per-worktree. The is_per_worktree_ref function and associated docs learn that refs/bisect/ is per-worktree, as does the git_path code in path.c The ref-packing functions learn that per-worktree refs should not be packed (since packed-refs is common rather than per-worktree). Since refs/bisect is per-worktree, logs/refs/bisect should be too. Signed-off-by: David Turner <dturner@twopensource.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
4e09cf2acf
commit
ce414b33ec
@ -160,6 +160,13 @@ test_expect_success 'pack ref directly below refs/' '
|
||||
test_path_is_missing .git/refs/top
|
||||
'
|
||||
|
||||
test_expect_success 'do not pack ref in refs/bisect' '
|
||||
git update-ref refs/bisect/local HEAD &&
|
||||
git pack-refs --all --prune &&
|
||||
! grep refs/bisect/local .git/packed-refs >/dev/null &&
|
||||
test_path_is_file .git/refs/bisect/local
|
||||
'
|
||||
|
||||
test_expect_success 'disable reflogs' '
|
||||
git config core.logallrefupdates false &&
|
||||
rm -rf .git/logs
|
||||
|
Reference in New Issue
Block a user