From 5a4131d4dd096daab615e9dd4c489deb2c42b4f8 Mon Sep 17 00:00:00 2001 From: Kellen Murphy Date: Sat, 16 May 2026 15:51:44 -0400 Subject: [PATCH] fix(ci): add --repo flag to gh commands in release-please workflow gh CLI has no git repo context in the release-please job (no checkout step), so it cannot auto-detect the repository. Adding --repo $GITHUB_REPOSITORY to all three gh commands resolves the error: 'failed to run git: fatal: not a git repository' --- .github/workflows/release-please.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/release-please.yml b/.github/workflows/release-please.yml index 886766b..846d37b 100644 --- a/.github/workflows/release-please.yml +++ b/.github/workflows/release-please.yml @@ -29,6 +29,6 @@ jobs: run: | PR_NUMBER=$(echo '${{ steps.release.outputs.pr }}' | jq -r '.number') PR_BRANCH=$(echo '${{ steps.release.outputs.pr }}' | jq -r '.headBranchName') - gh workflow run ci.yml --ref "$PR_BRANCH" - gh pr review "$PR_NUMBER" --approve --body "Approved by release-please automation." - gh pr merge --auto --merge "$PR_NUMBER" + gh workflow run ci.yml --ref "$PR_BRANCH" --repo "$GITHUB_REPOSITORY" + gh pr review "$PR_NUMBER" --approve --body "Approved by release-please automation." --repo "$GITHUB_REPOSITORY" + gh pr merge --auto --merge "$PR_NUMBER" --repo "$GITHUB_REPOSITORY"