From: Junio C Hamano Date: Thu, 11 Jan 2024 21:03:44 GMT Subject: Re: [PATCH 2/2] completion: silence pseudoref existence check Message-ID: In-Reply-To: <24563975fca8df6ae73917e9ee3534933d47c429.1704969119.git.ps@pks.im> Patrick Steinhardt writes: > In 44dbb3bf29 (completion: support pseudoref existence checks for > reftables, 2023-12-19), we have extended the Bash completion script to > support future ref backends better by using git-rev-parse(1) to check > for pseudo-ref existence. This conversion has introduced a bug, because > even though we pass `--quiet` to git-rev-parse(1) it would still output > the resolved object ID of the ref in question if it exists. > > Fix this by redirecting its stdout to `/dev/null` and add a test that > catches this behaviour. Note that the test passes even without the fix > for the "files" backend because we parse pseudo refs via the filesystem > directly in that case. But the test will fail with the "reftable" > backend. Thanks. Will queue.