git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH v2 1/7] refs: drop unnecessary header includes

From
SZEDER Gábor <szeder.dev@gmail.com>
Date
Jan 18, 2026, 12:07 UTC
Message-ID
<aWzM+qePiaRWz5/f@szeder.dev>
In-Reply-To
<20260116-633-regression-lost-diagnostic-message-when-pushing-non-commit-objects-to-refs-heads-v2-1-925a0e9c7f32@gmail.com>
On Fri, Jan 16, 2026 at 10:27:06PM +0100, Karthik Nayak wrote:
> The 'sigchain.h' header isn't being used and can be removed.
> 
> Similarly, 'run-command.h' serves no direct purpose here. While it gets pulled in transitively through 'hook.h', we can still drop the explicit include for clarity.

The need for these #includes went away fairly recently, I think in 26238496a7 (hook: provide stdin via callback, 2025-12-26) and 7a7717427e (reference-transaction: use hook API instead of run-command, 2025-12-26), which were merged in f406b89552 (Merge branch 'ar/run-command-hook', 2026-01-06). Unfortunately, that topic had some regressions and therefore was reverted in a3d1f391d3 (Revert "Merge branch 'ar/run-command-hook'", 2026-01-15), and as a result merging this topic into seen resulted in a merge commit 180b93f7ba (Merge branch 'kn/ref-batch-output-error-reporting-fix' into jch, 2026-01-16) that can't be built.

I think this patch should be dropped from this series, and these #includes should be removed in that other topic.

https://public-inbox.org/git/20251226122334.16687-1-adrian.ratiu@collabora.com/T/#u
Show 29 quoted lines
> Signed-off-by: Karthik Nayak <karthik.188@gmail.com>
> ---
>  refs.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/refs.c b/refs.c
> index e06e0cb072..965b232a06 100644
> --- a/refs.c
> +++ b/refs.c
> @@ -15,7 +15,6 @@
>  #include "iterator.h"
>  #include "refs.h"
>  #include "refs/refs-internal.h"
> -#include "run-command.h"
>  #include "hook.h"
>  #include "object-name.h"
>  #include "odb.h"
> @@ -26,7 +25,6 @@
>  #include "strvec.h"
>  #include "repo-settings.h"
>  #include "setup.h"
> -#include "sigchain.h"
>  #include "date.h"
>  #include "commit.h"
>  #include "wildmatch.h"
> 
> -- 
> 2.51.2
> 
Previous: Karthik NayakNext: Karthik Nayak
Message 3 of 12 in “refs: provide detailed error messages when using batched update”
  1. 0/7 refs: provide detailed error messages when using batched updateKarthik Nayak, Jan 16, 2026
  2. 1/7 refs: drop unnecessary header includesKarthik Nayak, Jan 16, 2026
  3. SZEDER GáborJan 18, 2026
  4. Karthik NayakJan 19, 2026
  5. 2/7 refs: skip to next ref when current ref is rejectedKarthik Nayak, Jan 16, 2026
  6. 3/7 refs: add rejection detail to the callback functionKarthik Nayak, Jan 16, 2026
  7. 4/7 update-ref: utilize rejected error details if availableKarthik Nayak, Jan 16, 2026
  8. 5/7 fetch: utilize rejected ref error detailsKarthik Nayak, Jan 16, 2026
  9. 6/7 receive-pack: utilize rejected ref error detailsKarthik Nayak, Jan 16, 2026
  10. 7/7 fetch: delay user information post committing of transactionKarthik Nayak, Jan 16, 2026
  11. Phillip WoodJan 17, 2026
  12. Karthik NayakJan 19, 2026

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.