Repository navigation
Merge pull request #5 from BrobridgeOrg/feat/v0.6.0-bundled-mcp #19
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: Package plugins | |
| on: | |
| push: | |
| tags: ['v*'] | |
| workflow_dispatch: | |
| inputs: | |
| tag: | |
| description: 'Optional existing tag (e.g. v0.3.1). Leave blank to package the selected branch without publishing a release.' | |
| required: false | |
| type: string | |
| permissions: | |
| contents: read | |
| concurrency: | |
| group: release-${{ inputs.tag || github.ref_name }} | |
| cancel-in-progress: false | |
| jobs: | |
| release: | |
| runs-on: ubuntu-latest | |
| env: | |
| RELEASE_TAG: ${{ inputs.tag || (github.ref_type == 'tag' && github.ref_name) || '' }} | |
| permissions: | |
| contents: write | |
| steps: | |
| - name: Validate release tag | |
| run: | | |
| if [[ -n "$RELEASE_TAG" ]]; then | |
| [[ "$RELEASE_TAG" =~ ^v[0-9]+\.[0-9]+\.[0-9]+$ ]] || exit 1 | |
| fi | |
| - uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1 | |
| with: | |
| ref: ${{ env.RELEASE_TAG != '' && format('refs/tags/{0}', env.RELEASE_TAG) || github.ref }} | |
| - name: Check plugin packages | |
| run: make check | |
| - name: Package ChatGPT and Claude plugins | |
| run: GITHUB_REF_NAME="$RELEASE_TAG" make release | |
| - name: Read package version | |
| id: package | |
| run: | | |
| version="$(cat VERSION)" | |
| [[ "$version" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]] || exit 1 | |
| echo "version=$version" >> "$GITHUB_OUTPUT" | |
| - name: Upload installation packages | |
| uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2 | |
| with: | |
| name: plasma-plugin-${{ steps.package.outputs.version }} | |
| path: | | |
| dist/v${{ steps.package.outputs.version }}/*.zip | |
| dist/v${{ steps.package.outputs.version }}/checksums.txt | |
| if-no-files-found: error | |
| retention-days: 30 | |
| - name: Publish release | |
| if: env.RELEASE_TAG != '' | |
| env: | |
| GH_TOKEN: ${{ github.token }} | |
| GH_REPO: ${{ github.repository }} | |
| run: | | |
| gh release create "$RELEASE_TAG" "dist/$RELEASE_TAG/"* \ | |
| --verify-tag --title "Plasma plugin $RELEASE_TAG" \ | |
| --notes-file "releases/$RELEASE_TAG.md" |