alexkurowski_solo-toolkit/.github/workflows/release.yml
2024-06-26 09:03:46 +08:00

40 lines
858 B
YAML

name: Release plugin
on:
push:
tags:
- "*"
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Use Node.js
uses: actions/setup-node@v3
with:
node-version: "18.x"
- name: Build plugin
run: |
npm install
npm run build
npm run deploy
cd dist
zip solo-rpg-toolkit.zip solo-rpg-toolkit/*
- name: Create release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
tag="${GITHUB_REF#refs/tags/}"
gh release create "$tag" \
--title="$tag" \
--draft \
dist/solo-rpg-toolkit.zip \
dist/solo-rpg-toolkit/main.js \
dist/solo-rpg-toolkit/manifest.json \
dist/solo-rpg-toolkit/styles.css