Re: [PATCH v4 03/13] t/perf: add pack-objects filter and path-walk benchmark
- From
Taylor Blau <me@ttaylorr.com>
- Date
- May 19, 2026, 23:51 UTC
- Message-ID
- <agz3fOHvVKGLMxgb@nand.local>
- In-Reply-To
- <fb8a0f9c43d4e41712839a93c4db6a294a7b5285.1778707135.git.gitgitgadget@gmail.com>
On Wed, May 13, 2026 at 09:18:45PM +0000, Derrick Stolee via GitGitGadget wrote:
Show 6 quoted lines
> + >depth2-dirs && > + while read tdir > + do > + git ls-tree -d --name-only "HEAD:$tdir" 2>/dev/null || return 1 > + done <top-dirs >depth2-dirs.raw && > + sed "s|^|$tdir/|" <depth2-dirs.raw >depth2-dirs &&
Ugh, I think that this was a bad suggestion on my part, since $tdir should be empty at this point.
Could we use --format here like so?
while read tdir
do
git ls-tree -d --format="$tdir/%(path)" "HEAD:$tdir" || return 1
done 2>/dev/nullI guess that breaks if $tdir contains a formatting atom, so perhaps we should keep the spirit of the original (but using an intermediary file instead of piping the output of Git to another command).
Sorry about that, I'm not sure why I thought that was a good idea when I wrote it :-<.
Thanks, Taylor