Update manifest and README #4
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 .mcpb | |
| on: | |
| push: | |
| branches: [main] | |
| permissions: | |
| contents: write | |
| jobs: | |
| # Run the full lint/format/typecheck/build suite; the release is gated on it. | |
| quality: | |
| uses: ./.github/workflows/quality.yml | |
| check: | |
| needs: quality | |
| runs-on: ubuntu-latest | |
| outputs: | |
| version: ${{ steps.version.outputs.version }} | |
| should_release: ${{ steps.check.outputs.should_release }} | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - name: Read version from package.json | |
| id: version | |
| run: echo "version=$(node -p "require('./package.json').version")" >> "$GITHUB_OUTPUT" | |
| - name: Check whether this version is already released | |
| id: check | |
| env: | |
| GH_TOKEN: ${{ github.token }} | |
| run: | | |
| if gh release view "v${{ steps.version.outputs.version }}" >/dev/null 2>&1; then | |
| echo "v${{ steps.version.outputs.version }} already released — skipping." | |
| echo "should_release=false" >> "$GITHUB_OUTPUT" | |
| else | |
| echo "should_release=true" >> "$GITHUB_OUTPUT" | |
| fi | |
| release: | |
| needs: check | |
| if: needs.check.outputs.should_release == 'true' | |
| runs-on: ubuntu-latest | |
| env: | |
| VERSION: ${{ needs.check.outputs.version }} | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - name: Set up Node | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version-file: .node-version | |
| - name: Enable Corepack (Yarn) | |
| run: corepack enable | |
| - name: Install dependencies | |
| run: yarn install | |
| - name: Build the .mcpb bundle | |
| run: yarn bundle | |
| - name: Create GitHub Release | |
| env: | |
| GH_TOKEN: ${{ github.token }} | |
| run: | | |
| gh release create "v${VERSION}" \ | |
| "companycam-mcp-server-${VERSION}.mcpb" \ | |
| --title "v${VERSION}" \ | |
| --generate-notes |