ci: remove obsolete MCP and dashboard integration tests #70
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Release | |
| # Builds and publishes release binaries when a version tag is pushed | |
| # Triggers: git tag -a v0.1.10 -m "Release v0.1.10" && git push origin v0.1.10 | |
| on: | |
| push: | |
| tags: | |
| - 'v*' | |
| workflow_dispatch: | |
| inputs: | |
| tag: | |
| description: 'Tag to release (e.g., v0.1.10)' | |
| required: true | |
| type: string | |
| permissions: | |
| contents: write | |
| jobs: | |
| # Build binaries for all platforms in parallel | |
| build-linux-x64: | |
| uses: ./.github/workflows/_build-release.yml | |
| with: | |
| os: ubuntu-latest | |
| target: x86_64-unknown-linux-gnu | |
| artifact-name: ie | |
| asset-name: intent-engine-linux-x86_64 | |
| build-linux-arm64: | |
| uses: ./.github/workflows/_build-release.yml | |
| with: | |
| os: ubuntu-latest | |
| target: aarch64-unknown-linux-gnu | |
| artifact-name: ie | |
| asset-name: intent-engine-linux-aarch64 | |
| build-macos-x64: | |
| uses: ./.github/workflows/_build-release.yml | |
| with: | |
| os: macos-latest | |
| target: x86_64-apple-darwin | |
| artifact-name: ie | |
| asset-name: intent-engine-macos-x86_64 | |
| build-macos-arm64: | |
| uses: ./.github/workflows/_build-release.yml | |
| with: | |
| os: macos-latest | |
| target: aarch64-apple-darwin | |
| artifact-name: ie | |
| asset-name: intent-engine-macos-aarch64 | |
| build-windows-x64: | |
| uses: ./.github/workflows/_build-release.yml | |
| with: | |
| os: windows-latest | |
| target: x86_64-pc-windows-msvc | |
| artifact-name: ie.exe | |
| asset-name: intent-engine-windows-x86_64.exe | |
| # Create GitHub Release | |
| release: | |
| name: Create GitHub Release | |
| needs: | |
| - build-linux-x64 | |
| - build-linux-arm64 | |
| - build-macos-x64 | |
| - build-macos-arm64 | |
| - build-windows-x64 | |
| runs-on: ubuntu-latest | |
| if: startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 0 | |
| - name: Download all artifacts | |
| uses: actions/download-artifact@v6 | |
| with: | |
| path: artifacts | |
| - name: Display artifact structure | |
| run: | | |
| echo "Artifact directory structure:" | |
| ls -lR artifacts/ | |
| - name: Get release tag | |
| id: tag | |
| run: | | |
| if [ "${{ github.event_name }}" == "workflow_dispatch" ]; then | |
| TAG="${{ inputs.tag }}" | |
| if [ -z "$TAG" ]; then | |
| echo "❌ Error: tag input is required for manual trigger" | |
| exit 1 | |
| fi | |
| else | |
| TAG=${GITHUB_REF#refs/tags/} | |
| fi | |
| echo "tag=$TAG" >> $GITHUB_OUTPUT | |
| echo "Release tag: $TAG" | |
| - name: Delete existing release (if exists) | |
| continue-on-error: true | |
| run: | | |
| gh release delete ${{ steps.tag.outputs.tag }} --yes | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Generate release notes | |
| id: notes | |
| run: | | |
| VERSION="${{ steps.tag.outputs.tag }}" | |
| echo "Generating release notes for $VERSION" | |
| # Get version from Cargo.toml | |
| CARGO_VERSION=$(grep '^version = ' Cargo.toml | head -1 | cut -d'"' -f2) | |
| # Generate changelog if CHANGELOG.md exists | |
| if [ -f "CHANGELOG.md" ]; then | |
| CHANGELOG=$(sed -n "/^## \[$CARGO_VERSION\]/,/^## \[/p" CHANGELOG.md | sed '$ d') | |
| fi | |
| # Create release notes file | |
| cat > release_notes.md << 'EOF' | |
| ## 🚀 What's Changed | |
| See [CHANGELOG.md](https://github.com/${{ github.repository }}/blob/main/CHANGELOG.md) for full details. | |
| ## 📦 Installation | |
| ### Using cargo-binstall (Recommended) | |
| ```bash | |
| cargo binstall intent-engine | |
| ``` | |
| ### Download Pre-built Binary | |
| Download the appropriate binary for your platform below. | |
| ### Build from Source | |
| ```bash | |
| cargo install --git https://github.com/${{ github.repository }} --tag $VERSION | |
| ``` | |
| ## 🔍 Verification | |
| After installation, verify with: | |
| ```bash | |
| ie --version | |
| ie doctor | |
| ``` | |
| ## 📚 Documentation | |
| - name: Delete existing release if it exists | |
| run: | | |
| set +e # Don't exit on error | |
| echo "Checking for existing release for tag: ${{ github.ref_name }}" | |
| # Try to get release info | |
| RESPONSE=$(curl -s -w "\n%{http_code}" -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \ | |
| "https://api.github.com/repos/${{ github.repository }}/releases/tags/${{ github.ref_name }}") | |
| HTTP_CODE=$(echo "$RESPONSE" | tail -n1) | |
| BODY=$(echo "$RESPONSE" | sed '$d') | |
| echo "HTTP Status: $HTTP_CODE" | |
| if [ "$HTTP_CODE" = "200" ]; then | |
| RELEASE_ID=$(echo "$BODY" | jq -r '.id') | |
| echo "Found existing release with ID: $RELEASE_ID" | |
| # Delete the release | |
| DELETE_RESPONSE=$(curl -s -w "\n%{http_code}" -X DELETE \ | |
| -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \ | |
| "https://api.github.com/repos/${{ github.repository }}/releases/$RELEASE_ID") | |
| DELETE_CODE=$(echo "$DELETE_RESPONSE" | tail -n1) | |
| if [ "$DELETE_CODE" = "204" ]; then | |
| echo "✅ Release deleted successfully" | |
| sleep 3 # Wait for GitHub to process | |
| else | |
| echo "⚠️ Failed to delete release. HTTP code: $DELETE_CODE" | |
| echo "Response: $(echo "$DELETE_RESPONSE" | sed '$d')" | |
| fi | |
| elif [ "$HTTP_CODE" = "404" ]; then | |
| echo "✅ No existing release found (fresh tag)" | |
| else | |
| echo "⚠️ Unexpected HTTP code when checking release: $HTTP_CODE" | |
| echo "Response: $BODY" | |
| fi | |
| set -e # Re-enable exit on error | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Create GitHub Release | |
| uses: softprops/action-gh-release@v2 | |
| with: | |
| tag_name: ${{ steps.tag.outputs.tag }} | |
| name: Release ${{ steps.tag.outputs.tag }} | |
| body_path: release_notes.md | |
| files: artifacts/**/* | |
| draft: false | |
| prerelease: false | |
| generate_release_notes: true | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Release summary | |
| run: | | |
| echo "## 🎉 Release Published" >> $GITHUB_STEP_SUMMARY | |
| echo "" >> $GITHUB_STEP_SUMMARY | |
| echo "**Version**: ${{ steps.tag.outputs.tag }}" >> $GITHUB_STEP_SUMMARY | |
| echo "**Binaries**: 5 platforms" >> $GITHUB_STEP_SUMMARY | |
| echo "" >> $GITHUB_STEP_SUMMARY | |
| echo "View release: https://github.com/${{ github.repository }}/releases/tag/${{ steps.tag.outputs.tag }}" >> $GITHUB_STEP_SUMMARY | |
| # Publish to crates.io | |
| publish-crates: | |
| name: Publish to crates.io | |
| needs: release | |
| runs-on: ubuntu-latest | |
| if: startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' | |
| steps: | |
| - name: Get release tag | |
| id: tag | |
| run: | | |
| if [ "${{ github.event_name }}" == "workflow_dispatch" ]; then | |
| TAG="${{ inputs.tag }}" | |
| if [ -z "$TAG" ]; then | |
| echo "❌ Error: tag input is required for manual trigger" | |
| exit 1 | |
| fi | |
| else | |
| TAG=${GITHUB_REF#refs/tags/} | |
| fi | |
| echo "tag=$TAG" >> $GITHUB_OUTPUT | |
| echo "Release tag: $TAG" | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| with: | |
| ref: ${{ steps.tag.outputs.tag }} | |
| - name: Setup Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| - name: Verify version matches tag | |
| run: | | |
| TAG_VERSION="${{ steps.tag.outputs.tag }}" | |
| TAG_VERSION=${TAG_VERSION#v} | |
| CARGO_VERSION=$(grep '^version = ' Cargo.toml | head -1 | cut -d'"' -f2) | |
| if [ "$TAG_VERSION" != "$CARGO_VERSION" ]; then | |
| echo "❌ Version mismatch!" | |
| echo "Tag version: $TAG_VERSION" | |
| echo "Cargo.toml version: $CARGO_VERSION" | |
| exit 1 | |
| fi | |
| echo "✅ Version verified: $CARGO_VERSION" | |
| - name: Dry run publish | |
| run: cargo publish --dry-run --allow-dirty | |
| - name: Publish to crates.io | |
| run: cargo publish --allow-dirty | |
| env: | |
| CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }} | |
| - name: Publish summary | |
| run: | | |
| VERSION=$(grep '^version = ' Cargo.toml | head -1 | cut -d'"' -f2) | |
| echo "## 📦 Published to crates.io" >> $GITHUB_STEP_SUMMARY | |
| echo "" >> $GITHUB_STEP_SUMMARY | |
| echo "**Version**: $VERSION" >> $GITHUB_STEP_SUMMARY | |
| echo "**Package**: https://crates.io/crates/intent-engine" >> $GITHUB_STEP_SUMMARY |