Skip to content
This repository was archived by the owner on Aug 6, 2026. It is now read-only.

feat(agent): tell cloud agents to upload deliverables as artifacts (#… #408

feat(agent): tell cloud agents to upload deliverables as artifacts (#…

feat(agent): tell cloud agents to upload deliverables as artifacts (#… #408

Workflow file for this run

name: Tag Agent Release
on:
push:
branches:
- main
paths:
- "packages/agent/**"
- ".github/workflows/agent-tag.yml"
- ".github/workflows/agent-release.yml"
concurrency:
group: agent-tag
cancel-in-progress: false
jobs:
tag:
permissions:
contents: write
runs-on: ubuntu-latest
steps:
- name: Get app token
id: app-token
uses: getsentry/action-github-app-token@5c1e90706fe007857338ac1bfbd7a4177db2f789 # v4.0.0
with:
app_id: ${{ secrets.GH_APP_ARRAY_RELEASER_APP_ID }}
private_key: ${{ secrets.GH_APP_ARRAY_RELEASER_PRIVATE_KEY }}
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
fetch-depth: 0
token: ${{ steps.app-token.outputs.token }}
- name: Compute version and create tag
env:
GH_TOKEN: ${{ steps.app-token.outputs.token }}
REPOSITORY: ${{ github.repository }}
run: |
# Find the latest agent base version tag (agent-vX.Y or agent-vX.Y.0 format)
LATEST_TAG=$(git tag --list 'agent-v[0-9]*.[0-9]*' --sort=-v:refname | grep -E '^agent-v[0-9]+\.[0-9]+(\.0)?$' | head -1)
if [ -z "$LATEST_TAG" ]; then
echo "No agent version tag found. Create one with: git tag agent-v2.1 && git push origin agent-v2.1"
exit 1
fi
# Extract major.minor from tag
VERSION_PART=${LATEST_TAG#agent-v}
MAJOR=$(echo "$VERSION_PART" | cut -d. -f1)
MINOR=$(echo "$VERSION_PART" | cut -d. -f2)
# Count commits since the base tag
PATCH=$(git rev-list "$LATEST_TAG"..HEAD --count)
if [ "$PATCH" -eq 0 ]; then
echo "No commits since $LATEST_TAG. Nothing to release."
exit 0
fi
NEW_VERSION="${MAJOR}.${MINOR}.${PATCH}"
TAG="agent-v$NEW_VERSION"
echo "Creating tag: $TAG (from base tag $LATEST_TAG + $PATCH commits)"
git config user.email "github-actions[bot]@users.noreply.github.com"
git config user.name "github-actions[bot]"
git tag -a "$TAG" -m "Agent release $TAG"
git push "https://x-access-token:${GH_TOKEN}@github.com/$REPOSITORY" "$TAG"