Skip to content

Commit 586a42a

Browse files
committed
chore(ci): Make release workflow URLs owner-agnostic
Replace hardcoded cameroncooke references with github.repository and github.repository_owner context variables so the workflow works correctly after org transfer.
1 parent e14acc7 commit 586a42a

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

.github/workflows/release.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,7 @@ jobs:
384384
if: env.HOMEBREW_TAP_TOKEN != ''
385385
run: |
386386
VERSION="${{ needs.release.outputs.version }}"
387-
FORMULA_BASE_URL="https://github.com/cameroncooke/XcodeBuildMCP/releases/download/v${VERSION}"
387+
FORMULA_BASE_URL="https://github.com/${{ github.repository }}/releases/download/v${VERSION}"
388388
ARM64_SHA="$(awk '{print $1}' dist/portable/arm64/xcodebuildmcp-${VERSION}-darwin-arm64.tar.gz.sha256)"
389389
X64_SHA="$(awk '{print $1}' dist/portable/x64/xcodebuildmcp-${VERSION}-darwin-x64.tar.gz.sha256)"
390390
npm run homebrew:formula -- \
@@ -401,14 +401,14 @@ jobs:
401401
run: |
402402
VERSION="${{ needs.release.outputs.version }}"
403403
DEFAULT_BRANCH="main"
404-
gh repo clone cameroncooke/homebrew-xcodebuildmcp tap-repo
404+
gh repo clone ${{ github.repository_owner }}/homebrew-xcodebuildmcp tap-repo
405405
mkdir -p tap-repo/Formula
406406
cp dist/homebrew/Formula/xcodebuildmcp.rb tap-repo/Formula/xcodebuildmcp.rb
407407
cd tap-repo
408408
git config user.name "github-actions[bot]"
409409
git config user.email "github-actions[bot]@users.noreply.github.com"
410-
git remote set-url origin "https://x-access-token:${HOMEBREW_TAP_TOKEN}@github.com/cameroncooke/homebrew-xcodebuildmcp.git"
411-
DETECTED_BRANCH="$(gh repo view cameroncooke/homebrew-xcodebuildmcp --json defaultBranchRef -q .defaultBranchRef.name 2>/dev/null || true)"
410+
git remote set-url origin "https://x-access-token:${HOMEBREW_TAP_TOKEN}@github.com/${{ github.repository_owner }}/homebrew-xcodebuildmcp.git"
411+
DETECTED_BRANCH="$(gh repo view ${{ github.repository_owner }}/homebrew-xcodebuildmcp --json defaultBranchRef -q .defaultBranchRef.name 2>/dev/null || true)"
412412
if [ -n "$DETECTED_BRANCH" ]; then
413413
DEFAULT_BRANCH="$DETECTED_BRANCH"
414414
fi

0 commit comments

Comments
 (0)