Skip to content

v1.4.0

v1.4.0 #4

---
name: Build and Release IDE Bundles
on:
release:
types: [published]
jobs:
build-and-release:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
ref: ${{ github.event.release.tag_name }}
- name: Install uv
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install dependencies
run: uv sync --locked
- name: Get version from release
id: get_version
env:
TAG: ${{ github.event.release.tag_name }}
run: |
VERSION=${TAG#v}
echo "tag=$TAG" >> "$GITHUB_OUTPUT"
echo "version=$VERSION" >> "$GITHUB_OUTPUT"
echo "Release version: $VERSION (tag: $TAG)"
- name: Validate rules
run: uv run python src/validate_unified_rules.py sources/
- name: Validate versions match tag
env:
VERSION: ${{ steps.get_version.outputs.version }}
run: uv run python src/validate_versions.py "$VERSION"
- name: Generate IDE bundles
run: uv run python src/convert_to_ide_formats.py
- name: Create release archives
shell: bash
run: |
cd dist
zip -r ../codeguard-claude.zip .claude/
zip -r ../codeguard-cursor.zip .cursor/
zip -r ../codeguard-windsurf.zip .windsurf/
zip -r ../codeguard-copilot.zip .github/
# Antigravity + Codex share .agents/; scope each zip to its own subpath.
zip -r ../codeguard-antigravity.zip .agents/rules/
zip -r ../codeguard-opencode.zip .opencode/
zip -r ../codeguard-codex.zip .agents/skills/
zip -r ../codeguard-openclaw.zip .openclaw/
zip -r ../codeguard-hermes.zip .hermes/
cd ..
zip -r codeguard-all.zip dist/
sha256sum codeguard-*.zip > SHA256SUMS
sha256sum --check SHA256SUMS
ls -lh codeguard-*.zip SHA256SUMS
- name: Upload release assets
shell: bash
env:
GH_TOKEN: ${{ github.token }}
TAG: ${{ steps.get_version.outputs.tag }}
run: |
gh release upload "$TAG" codeguard-*.zip SHA256SUMS