Skip to content

Merge pull request #7 from wp-graphql/misc #11

Merge pull request #7 from wp-graphql/misc

Merge pull request #7 from wp-graphql/misc #11

Workflow file for this run

name: Release Plugin
on:
push:
tags:
- 'v*'
jobs:
build-and-release:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20]
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- name: Install Dependencies using npm ci
run: npm ci
- name: Run Lint and Tests
run: |
npm run lint:js
npm run test
- name: Build Package
run: npm run build
- name: Zip Artifacts
run: |
mkdir -p wpgraphql-ide/
rsync -av --exclude-from='.distignore' --delete-excluded ./ wpgraphql-ide/ && zip -r wpgraphql-ide.zip wpgraphql-ide/ && rm -rf wpgraphql-ide/
ls -la
- name: Upload release artifact
uses: softprops/action-gh-release@v1
with:
files: wpgraphql-ide.zip
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
permissions:
contents: write