Skip to content

Create Release

Create Release #244

Workflow file for this run

name: Create Release
on:
# Trigger when Update workflow completes (bypasses GITHUB_TOKEN limitation)
workflow_run:
workflows: ["Update Google Antigravity"]
types:
- completed
# Keep push trigger for manual merges by humans
push:
branches:
- master
paths:
- "artifacts/versions.json"
# Allow manual trigger
workflow_dispatch:
permissions:
contents: write
jobs:
create-release:
name: Create GitHub release
runs-on: ubuntu-latest
# Only run if: workflow_dispatch, push event, OR workflow_run that succeeded
if: |
github.event_name == 'workflow_dispatch' ||
github.event_name == 'push' ||
(github.event_name == 'workflow_run' && github.event.workflow_run.conclusion == 'success')
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 2
- name: Check if release needed
id: release_check
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
extract_version() { jq -r ".\"$1\".\"x86_64-linux\".url" artifacts/versions.json | grep -oP '[0-9]+\.[0-9]+\.[0-9]+-[0-9]+'; }
# The 2.0 app is the flagship/default package, so the release is tagged by its version.
APP_VERSION=$(extract_version "Antigravity 2.0")
IDE_VERSION=$(extract_version "Antigravity IDE")
CLI_VERSION=$(extract_version "Antigravity CLI")
CURRENT_VERSION="$APP_VERSION"
echo "current_version=$CURRENT_VERSION" >> $GITHUB_OUTPUT
echo "app_version=$APP_VERSION" >> $GITHUB_OUTPUT
echo "ide_version=$IDE_VERSION" >> $GITHUB_OUTPUT
echo "cli_version=$CLI_VERSION" >> $GITHUB_OUTPUT
echo "Versions — app: $APP_VERSION, ide: $IDE_VERSION, cli: $CLI_VERSION"
# Check if release already exists for this version
if gh release view "v$CURRENT_VERSION" >/dev/null 2>&1; then
echo "should_release=false" >> $GITHUB_OUTPUT
echo "Release v$CURRENT_VERSION already exists, skipping"
else
echo "should_release=true" >> $GITHUB_OUTPUT
echo "Release v$CURRENT_VERSION does not exist, will create"
fi
- name: Create release
if: steps.release_check.outputs.should_release == 'true'
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
VERSION: ${{ steps.release_check.outputs.current_version }}
APP_VERSION: ${{ steps.release_check.outputs.app_version }}
IDE_VERSION: ${{ steps.release_check.outputs.ide_version }}
CLI_VERSION: ${{ steps.release_check.outputs.cli_version }}
run: |
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
git tag -a "v$VERSION" -m "Google Antigravity v$VERSION"
git push origin "v$VERSION"
gh release create "v$VERSION" \
--title "Google Antigravity v$VERSION" \
--notes "Auto-updated Google Antigravity packages.
| Component | Version |
| --- | --- |
| Antigravity 2.0 app (\`default\`) | $APP_VERSION |
| Antigravity IDE | $IDE_VERSION |
| Antigravity CLI (\`agy\`) | $CLI_VERSION |
## Installation
\`\`\`nix
inputs.antigravity-nix.url = \"github:jacopone/antigravity-nix/v$VERSION\";
\`\`\`
## What's New
See: https://antigravity.google/releases
## Notes
- 📦 Multi-platform: Linux & macOS (x86_64, aarch64)
- 🔧 FHS + no-FHS variants for the GUI apps
- ✅ Hashes verified by build before release"
echo "✓ Created release v$VERSION"