From e79d72accb7eafb733060881939163244f5df5d1 Mon Sep 17 00:00:00 2001 From: Shai Almog <67850168+shai-almog@users.noreply.github.com> Date: Fri, 5 Jun 2026 13:47:38 +0300 Subject: [PATCH] Fix native-themes-sync git commit-back: mark workspace safe.directory With the packages:read fix (#5172) the container pull now succeeds, so the "Commit and push regenerated .res files" step ran for the first time and failed with "fatal: not in a git directory" (exit 128). The job runs inside the pr-ci-container, where the checked-out tree is owned by a different UID than the shell step's user. git's dubious- ownership guard then refuses every command. actions/checkout records a safe.directory entry, but in the action's HOME, which the bash run step doesn't share -- so add the workspace to safe.directory explicitly before the git config/commit/push calls. Co-Authored-By: Claude Opus 4.8 (1M context) --- .github/workflows/native-themes-sync.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/native-themes-sync.yml b/.github/workflows/native-themes-sync.yml index 7985a6aaf0..b21a5f3b25 100644 --- a/.github/workflows/native-themes-sync.yml +++ b/.github/workflows/native-themes-sync.yml @@ -70,6 +70,13 @@ jobs: - name: Commit and push regenerated .res files run: | set -euo pipefail + # This job runs inside the pr-ci-container, where the checked-out + # tree is owned by a different UID than this shell step's user. + # git's dubious-ownership guard then rejects every command with + # "fatal: not in a git directory". actions/checkout writes a + # safe.directory entry, but into the action's HOME, which this + # bash step doesn't share -- so mark the workspace safe here too. + git config --global --add safe.directory "$GITHUB_WORKSPACE" git config user.name "github-actions[bot]" git config user.email "41898282+github-actions[bot]@users.noreply.github.com" # Themes/ holds the single source of truth. Each downstream consumer