From ef20b0d6c322a1f2e98b929b80ae9d4c1f9d9f75 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Kr=C3=BCger?= Date: Sat, 22 Aug 2026 18:17:41 +0200 Subject: [PATCH] Fix CI: vendor-fetch commit fails with no git identity configured scripts/setup.sh's fetch_pinned() creates a fresh git repo per vendored dependency and commits it with --author set, but --author alone doesn't satisfy git's separate committer-identity requirement - it works on a dev machine with ~/.gitconfig already set, but fails outright in a clean CI container with no git identity anywhere (confirmed: Gitea Actions failed at exactly this step with "Committer identity unknown"). Fixed by scoping user.name/user.email via -c flags to just this commit invocation, verified to succeed even with HOME pointed at an empty directory and no inherited git env vars. Co-Authored-By: Claude Sonnet 5 --- scripts/setup.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/scripts/setup.sh b/scripts/setup.sh index a67a22f..ebb6803 100755 --- a/scripts/setup.sh +++ b/scripts/setup.sh @@ -52,7 +52,12 @@ fetch_pinned() { rm -f "/tmp/${name}-${sha}.tar.gz" git -C "$dest" init -q git -C "$dest" add -A - git -C "$dest" commit -q -m "vendor: $name @ $sha" --author="vpinball-wasm setup " + # -c user.name/user.email (not --author) are needed here: --author only sets + # the commit's author field, but git also requires a *committer* identity, + # which a fresh CI container has no ~/.gitconfig to supply. Scoped to this + # one invocation only - doesn't touch any persistent git config. + git -C "$dest" -c user.name="vpinball-wasm setup" -c user.email="noreply@localhost" \ + commit -q -m "vendor: $name @ $sha" --author="vpinball-wasm setup " echo "$sha" > "$sentinel" }