You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Let nonstandard worktree fixtures work even if Git < 2.37.2
This reorders the operations in the nonstandard worktree fixtures
to work even when Git is at a lower version than 2.37.2. This makes
root_enters_directory_with_dot_git_in_reconfigured_worktree_tracked
pass on more systems, including common development systems.
When fixture scripts are run on a system whose Git version is lower
than 2.37.2, including currently maintained downstream versions
with backported security (but not most other) fixes on some popular
OSes (e.g. Ubuntu 22.04.4 LTS with 2.34.1-1ubuntu1.10), the gix-dir
nonstandard worktree fixtures had silently failed to stage one of
two intended files. They appeared to succeed, but created a repo
with only the "seemingly-outside" file, and not the "inside" file.
This is due to the bug git/git@27128996b8
fixed in Git. The nonstandard worktree fixtures had needed Git to
support the first condition noted there, where core.worktree is the
parent of the default worktree, in order to stage both files.
The change made here overcomes the problem by staging before rather
than after moving .git and setting core.worktree. The `git add`
command used to stage is adjusted to remain equivalent in its
effect. (Committing can be, and is, still done last.)
CI hadn't suffered/shown the problem, since while GHA ubuntu-latest
runners are currently Ubuntu 22.04, they have many newer software
versions installed on them, currently including Git 2.43.2.
0 commit comments