chore(cueme): bump version to 0.1.17 #1
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: Publish Packages | |
| on: | |
| push: | |
| tags: | |
| - 'release-*' | |
| jobs: | |
| detect-changes: | |
| runs-on: ubuntu-latest | |
| outputs: | |
| console-changed: ${{ steps.check.outputs.console }} | |
| command-changed: ${{ steps.check.outputs.command }} | |
| mcp-changed: ${{ steps.check.outputs.mcp }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 2 | |
| - name: Check version changes | |
| id: check | |
| run: | | |
| # Get previous release tag | |
| PREV_TAG=$(git tag --sort=-version:refname | grep "^release-" | sed -n '2p') | |
| if [ -z "$PREV_TAG" ]; then | |
| # First release, publish all | |
| echo "console=true" >> $GITHUB_OUTPUT | |
| echo "command=true" >> $GITHUB_OUTPUT | |
| echo "mcp=true" >> $GITHUB_OUTPUT | |
| else | |
| # Check if version files changed | |
| if git diff $PREV_TAG HEAD -- cue-console/package.json | grep -q '"version"'; then | |
| echo "console=true" >> $GITHUB_OUTPUT | |
| else | |
| echo "console=false" >> $GITHUB_OUTPUT | |
| fi | |
| if git diff $PREV_TAG HEAD -- cue-command/package.json | grep -q '"version"'; then | |
| echo "command=true" >> $GITHUB_OUTPUT | |
| else | |
| echo "command=false" >> $GITHUB_OUTPUT | |
| fi | |
| if git diff $PREV_TAG HEAD -- cue-mcp/pyproject.toml cue-mcp/cuemcp/__init__.py | grep -q 'version'; then | |
| echo "mcp=true" >> $GITHUB_OUTPUT | |
| else | |
| echo "mcp=false" >> $GITHUB_OUTPUT | |
| fi | |
| fi | |
| publish-console: | |
| needs: detect-changes | |
| if: needs.detect-changes.outputs.console-changed == 'true' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: pnpm/action-setup@v2 | |
| with: | |
| version: 8 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| registry-url: 'https://registry.npmjs.org' | |
| - name: Install dependencies | |
| run: pnpm install | |
| - name: Build | |
| run: pnpm --filter cue-console build | |
| - name: Publish to npm | |
| run: pnpm --filter cue-console publish --no-git-checks | |
| env: | |
| NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | |
| publish-command: | |
| needs: detect-changes | |
| if: needs.detect-changes.outputs.command-changed == 'true' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: pnpm/action-setup@v2 | |
| with: | |
| version: 8 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| registry-url: 'https://registry.npmjs.org' | |
| - name: Install dependencies | |
| run: pnpm install | |
| - name: Publish to npm | |
| run: pnpm --filter cueme publish --no-git-checks | |
| env: | |
| NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | |
| publish-mcp: | |
| needs: detect-changes | |
| if: needs.detect-changes.outputs.mcp-changed == 'true' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: astral-sh/setup-uv@v5 | |
| with: | |
| enable-cache: true | |
| - name: Build package | |
| run: uv build cue-mcp | |
| - name: Publish to PyPI | |
| run: uv publish cue-mcp/dist/* | |
| env: | |
| UV_PUBLISH_TOKEN: ${{ secrets.PYPI_TOKEN }} | |
| create-release: | |
| needs: [detect-changes, publish-console, publish-command, publish-mcp] | |
| if: always() | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Extract versions | |
| id: versions | |
| run: | | |
| CONSOLE_VER=$(grep '"version"' cue-console/package.json | head -1 | sed 's/.*"version": "\(.*\)".*/\1/') | |
| COMMAND_VER=$(grep '"version"' cue-command/package.json | head -1 | sed 's/.*"version": "\(.*\)".*/\1/') | |
| MCP_VER=$(grep '^version = ' cue-mcp/pyproject.toml | sed 's/version = "\(.*\)"/\1/') | |
| echo "console=$CONSOLE_VER" >> $GITHUB_OUTPUT | |
| echo "command=$COMMAND_VER" >> $GITHUB_OUTPUT | |
| echo "mcp=$MCP_VER" >> $GITHUB_OUTPUT | |
| - name: Create Release | |
| uses: actions/create-release@v1 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| with: | |
| tag_name: ${{ github.ref_name }} | |
| release_name: Release ${{ github.ref_name }} | |
| body: | | |
| ## Published Packages | |
| ${{ needs.detect-changes.outputs.console-changed == 'true' && format('- ✅ `cue-console@{0}`', steps.versions.outputs.console) || '- ⏭️ cue-console (no changes)' }} | |
| ${{ needs.detect-changes.outputs.command-changed == 'true' && format('- ✅ `cueme@{0}`', steps.versions.outputs.command) || '- ⏭️ cueme (no changes)' }} | |
| ${{ needs.detect-changes.outputs.mcp-changed == 'true' && format('- ✅ `cuemcp@{0}`', steps.versions.outputs.mcp) || '- ⏭️ cuemcp (no changes)' }} | |
| ## Changes | |
| <!-- Add your release notes here --> | |
| draft: false | |
| prerelease: false |