skiff-cli 0.1.2

Progressive MCP / OpenAPI / GraphQL CLI for agents — fast warm discovery, sessions, spool
Documentation
name: Release

on:
  push:
    tags:
      - "v*"

permissions:
  contents: write

env:
  CARGO_TERM_COLOR: always

jobs:
  build:
    strategy:
      fail-fast: false
      matrix:
        include:
          - os: macos-14
            target: aarch64-apple-darwin
            artifact: skiff-aarch64-apple-darwin
          - os: macos-14
            target: x86_64-apple-darwin
            artifact: skiff-x86_64-apple-darwin
          - os: ubuntu-latest
            target: x86_64-unknown-linux-gnu
            artifact: skiff-x86_64-unknown-linux-gnu
    runs-on: ${{ matrix.os }}
    steps:
      - uses: actions/checkout@v4
      - uses: dtolnay/rust-toolchain@stable
        with:
          targets: ${{ matrix.target }}
      - uses: Swatinem/rust-cache@v2
        with:
          key: release-${{ matrix.target }}
      - name: Build release
        run: cargo build --release --locked --target ${{ matrix.target }}
      - name: Package
        shell: bash
        run: |
          BIN="target/${{ matrix.target }}/release/skiff"
          STAGE="${{ matrix.artifact }}"
          mkdir -p "$STAGE"
          cp "$BIN" "$STAGE/skiff"
          chmod +x "$STAGE/skiff"
          tar -czf "${STAGE}.tar.gz" "$STAGE"
          shasum -a 256 "${STAGE}.tar.gz" > "${STAGE}.tar.gz.sha256"
      - uses: actions/upload-artifact@v4
        with:
          name: ${{ matrix.artifact }}
          path: |
            ${{ matrix.artifact }}.tar.gz
            ${{ matrix.artifact }}.tar.gz.sha256

  publish:
    needs: build
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: actions/download-artifact@v4
        with:
          path: dist
          merge-multiple: true
      - name: Create GitHub Release
        uses: softprops/action-gh-release@v2
        with:
          generate_release_notes: true
          files: dist/*
          body: |
            ## skiff ${{ github.ref_name }}

            Progressive MCP / OpenAPI / GraphQL CLI (Rust).

            ### Install
            ```bash
            brew tap samikh-git/tools && brew install skiff
            cargo install skiff-cli
            ```

            Or download a binary tarball from the assets below.
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

  # Bumps Formula/skiff.rb in samikh-git/homebrew-tools (url + sha256 for the tag archive).
  # Needs repo secret HOMEBREW_TAP_TOKEN: a PAT with Contents write on samikh-git/homebrew-tools
  # (classic: repo scope, or fine-grained: Contents R/W on that tap only).
  homebrew:
    name: Bump Homebrew formula
    needs: publish
    if: ${{ !contains(github.ref_name, '-') }}
    runs-on: ubuntu-latest
    steps:
      - uses: mislav/bump-homebrew-formula-action@v4
        with:
          formula-name: skiff
          homebrew-tap: samikh-git/homebrew-tools
          tag-name: ${{ github.ref_name }}
          commit-message: |
            skiff {{version}}

            Automated by the skiff Release workflow.
        env:
          COMMITTER_TOKEN: ${{ secrets.HOMEBREW_TAP_TOKEN }}