Skip to content

Commit 0d15e5c

Browse files
committed
No need to actually create the directories
Because committing the staged paths creates the necessary Git tree objects irrespective of what directories exist or are otherwise represented. In addition to simplifying the proof-of-concept repository, this also makes it so its entries are properly ordered in its Git object database, so `git fsck` does not report errors about that, and exits reporting success (though of course still warns about the presence of `..` components).
1 parent 9180dde commit 0d15e5c

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

gix-worktree/tests/fixtures/make_traverse_dotdot_trees.sh

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,8 @@ for subdir in .a .b .c .d .e .f .g .h .i .j; do
2222
target="$subdir/$upward/$target_bin/ls"
2323
standin="$(printf '%s' "$target" | tr / @)"
2424

25-
mkdir -- "$subdir"
26-
touch -- "$subdir/.keep"
2725
cp -- payload "$standin"
28-
git add -- "$subdir/.keep" "$standin"
26+
git add -- "$standin"
2927

3028
standin_pattern="$(printf '%s' "$standin" | sed 's|\.|\\\.|g')"
3129
cp .git/index old_index

0 commit comments

Comments
 (0)