Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
65 changes: 0 additions & 65 deletions .github/workflows/build-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -741,71 +741,6 @@ jobs:
with:
verbose: true

# Update Homebrew formula (only stable releases from public repo)
update-homebrew:
name: Update Homebrew Formula
runs-on: ubuntu-latest
needs: [build-and-test, build-and-validate-macos-intel, build-and-validate-macos-arm, integration-tests, release-validation, create-release, publish-pypi]
if: github.ref_type == 'tag' && needs.create-release.outputs.is_private_repo != 'true' && needs.create-release.outputs.is_prerelease != 'true'
permissions:
contents: read

steps:
- name: Extract SHA256 checksums from GitHub release
id: checksums
run: |
# Download the SHA256 checksum files from the GitHub release
RELEASE_TAG="${{ github.ref_name }}"

echo "Downloading checksums for release $RELEASE_TAG"

# Download checksum files directly from the release
curl -L -o apm-darwin-arm64.tar.gz.sha256 \
"https://github.com/${{ github.repository }}/releases/download/$RELEASE_TAG/apm-darwin-arm64.tar.gz.sha256"
curl -L -o apm-darwin-x86_64.tar.gz.sha256 \
"https://github.com/${{ github.repository }}/releases/download/$RELEASE_TAG/apm-darwin-x86_64.tar.gz.sha256"
curl -L -o apm-linux-x86_64.tar.gz.sha256 \
"https://github.com/${{ github.repository }}/releases/download/$RELEASE_TAG/apm-linux-x86_64.tar.gz.sha256"
curl -L -o apm-linux-arm64.tar.gz.sha256 \
"https://github.com/${{ github.repository }}/releases/download/$RELEASE_TAG/apm-linux-arm64.tar.gz.sha256"

# Extract SHA256 checksums
DARWIN_ARM64_SHA=$(cat apm-darwin-arm64.tar.gz.sha256 | cut -d' ' -f1)
DARWIN_X86_64_SHA=$(cat apm-darwin-x86_64.tar.gz.sha256 | cut -d' ' -f1)
LINUX_X86_64_SHA=$(cat apm-linux-x86_64.tar.gz.sha256 | cut -d' ' -f1)
LINUX_ARM64_SHA=$(cat apm-linux-arm64.tar.gz.sha256 | cut -d' ' -f1)

echo "darwin-arm64-sha=$DARWIN_ARM64_SHA" >> $GITHUB_OUTPUT
echo "darwin-x86_64-sha=$DARWIN_X86_64_SHA" >> $GITHUB_OUTPUT
echo "linux-x86_64-sha=$LINUX_X86_64_SHA" >> $GITHUB_OUTPUT
echo "linux-arm64-sha=$LINUX_ARM64_SHA" >> $GITHUB_OUTPUT

echo "Darwin ARM64 SHA: $DARWIN_ARM64_SHA"
echo "Darwin x86_64 SHA: $DARWIN_X86_64_SHA"
echo "Linux x86_64 SHA: $LINUX_X86_64_SHA"
echo "Linux ARM64 SHA: $LINUX_ARM64_SHA"

- name: Trigger Homebrew tap repository update
uses: peter-evans/repository-dispatch@v3
with:
token: ${{ secrets.GH_PKG_PAT }}
repository: microsoft/homebrew-apm
event-type: formula-update
client-payload: |
{
"release": {
"version": "${{ github.ref_name }}",
"tag": "${{ github.ref_name }}",
"repository": "${{ github.repository }}"
},
"checksums": {
"darwin_arm64": "${{ steps.checksums.outputs.darwin-arm64-sha }}",
"darwin_x86_64": "${{ steps.checksums.outputs.darwin-x86_64-sha }}",
"linux_x86_64": "${{ steps.checksums.outputs.linux-x86_64-sha }}",
"linux_arm64": "${{ steps.checksums.outputs.linux-arm64-sha }}"
}
}

# Update Scoop bucket (only stable releases from public repo)
update-scoop:
name: Update Scoop Bucket
Expand Down
Loading