Add example plugin build and run main from update-wit
This commit is contained in:
parent
48acc19760
commit
a62dca0239
@ -1,15 +1,16 @@
|
||||
name: Release
|
||||
name: Main
|
||||
on:
|
||||
push:
|
||||
workflow_dispatch:
|
||||
workflow_call:
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
pull-requests: write
|
||||
|
||||
jobs:
|
||||
release:
|
||||
name: Build and release
|
||||
main:
|
||||
name: Build, test, and release
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
@ -29,6 +30,14 @@ jobs:
|
||||
- name: Build
|
||||
run: npm pack
|
||||
|
||||
- name: Build example plugin to test
|
||||
run: |
|
||||
set -eux
|
||||
|
||||
cd example
|
||||
npm install ../*.tgz
|
||||
npm run build
|
||||
|
||||
- name: Set GITHUB_RELEASE_TAG & ARTIFACT_ID
|
||||
run: |
|
||||
set -eux
|
||||
8
.github/workflows/update-wit.yml
vendored
8
.github/workflows/update-wit.yml
vendored
@ -4,11 +4,12 @@ on:
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
pull-requests: write
|
||||
|
||||
jobs:
|
||||
update-wit:
|
||||
name: Update WIT
|
||||
runs-on: ubuntu-latest
|
||||
runs-on: ubuntu-slim
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v6
|
||||
@ -37,3 +38,8 @@ jobs:
|
||||
git add wit
|
||||
git commit -m "Sync to Pumpkin-MC/pumpkin-plugin-wit@${witCommit}"
|
||||
git push
|
||||
|
||||
main:
|
||||
name: Build, test, and release
|
||||
needs: update-wit
|
||||
uses: ./.github/workflows/main.yml
|
||||
|
||||
5
example/package.json
Normal file
5
example/package.json
Normal file
@ -0,0 +1,5 @@
|
||||
{
|
||||
"scripts": {
|
||||
"build": "pumpkin-plugin-build my-plugin.ts build/plugin.wasm"
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user