Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 41 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,44 @@ jobs:

- name: Run tests
run: pnpm test

auto-release:
runs-on: ubuntu-latest
if: github.event_name == 'push' && github.ref == 'refs/heads/main' && contains(github.event.head_commit.message, 'elease')
needs: build
permissions:
contents: write

steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Extract version from package.json
id: get_version
run: |
VERSION=$(node -p "require('./packages/claude-code-plugin-rest-api/package.json').version")
echo "version=$VERSION" >> $GITHUB_OUTPUT
echo "tag=v$VERSION" >> $GITHUB_OUTPUT

- name: Check if tag exists
id: check_tag
run: |
if git rev-parse "v${{ steps.get_version.outputs.version }}" >/dev/null 2>&1; then
echo "exists=true" >> $GITHUB_OUTPUT
else
echo "exists=false" >> $GITHUB_OUTPUT
fi

- name: Create and push tag
if: steps.check_tag.outputs.exists == 'false'
run: |
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
git tag ${{ steps.get_version.outputs.tag }}
git push origin ${{ steps.get_version.outputs.tag }}

- name: Skip tag creation
if: steps.check_tag.outputs.exists == 'true'
run: |
echo "Tag ${{ steps.get_version.outputs.tag }} already exists, skipping tag creation"
2 changes: 1 addition & 1 deletion packages/claude-code-plugin-rest-api/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@tigz/claude-code-plugin-rest-api",
"version": "1.0.6",
"version": "1.1.0",
"description": "NestJS module for exposing Claude Code plugins as REST APIs",
"type": "module",
"main": "dist/index.js",
Expand Down