diff --git a/.github/workflows/backend-pr-ci.yml b/.github/workflows/backend-pr-ci.yml index d933904..cd38c89 100644 --- a/.github/workflows/backend-pr-ci.yml +++ b/.github/workflows/backend-pr-ci.yml @@ -66,8 +66,14 @@ jobs: go-version: ${{ env.GO_VERSION }} cache-dependency-path: backend/go.sum + - name: Setup TinyGo + run: | + set -euo pipefail + curl -sL -o /tmp/tinygo.deb https://github.com/tinygo-org/tinygo/releases/download/v0.41.1/tinygo_0.41.1_amd64.deb + sudo dpkg -i /tmp/tinygo.deb + - name: Build WASM - run: GOOS=wasip1 GOARCH=wasm go build -buildmode=c-shared -o webhook.wasm . + run: tinygo build -target=wasip1 -buildmode=c-shared -o webhook.wasm . test: name: Tests diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 2b12767..f548749 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -22,6 +22,12 @@ jobs: with: go-version: "1.24" + - name: Setup TinyGo + run: | + set -euo pipefail + curl -sL -o /tmp/tinygo.deb https://github.com/tinygo-org/tinygo/releases/download/v0.41.1/tinygo_0.41.1_amd64.deb + sudo dpkg -i /tmp/tinygo.deb + - name: Setup Bun uses: oven-sh/setup-bun@v2 with: @@ -32,7 +38,7 @@ jobs: run: | set -euo pipefail mkdir -p ../release/backend - GOOS=wasip1 GOARCH=wasm go build -buildmode=c-shared -o ../release/backend/webhook.wasm . + tinygo build -target=wasip1 -buildmode=c-shared -o ../release/backend/webhook.wasm . - name: Build frontend working-directory: frontend diff --git a/backend/go.mod b/backend/go.mod index 0df49a0..a1b836d 100644 --- a/backend/go.mod +++ b/backend/go.mod @@ -2,4 +2,4 @@ module github.com/Paca-AI/first-party/webhook go 1.24 -require github.com/Paca-AI/plugin-sdk-go v0.2.0 +require github.com/Paca-AI/plugin-sdk-go v0.3.3 diff --git a/backend/go.sum b/backend/go.sum index 8389b8f..970bd41 100644 --- a/backend/go.sum +++ b/backend/go.sum @@ -1,2 +1,2 @@ -github.com/Paca-AI/plugin-sdk-go v0.2.0 h1:Fur6p+OQoC5imq7qmvaQtJnZ3SRVRskx8KcT/rqFHj4= -github.com/Paca-AI/plugin-sdk-go v0.2.0/go.mod h1:5WeC6cSEf2wM1ovICZbDaVky9oi5id/Qpdfc5LDAQnw= +github.com/Paca-AI/plugin-sdk-go v0.3.3 h1:nW2DwJatraYfxo4MpwNkfQEp+9jmj7QHaU16bOXzBpM= +github.com/Paca-AI/plugin-sdk-go v0.3.3/go.mod h1:5WeC6cSEf2wM1ovICZbDaVky9oi5id/Qpdfc5LDAQnw= diff --git a/plugin.json b/plugin.json index cc10ed8..9b6feed 100644 --- a/plugin.json +++ b/plugin.json @@ -2,8 +2,8 @@ "id": "com.paca.webhook", "displayName": "Webhooks", "description": "Sends HTTP webhooks to a URL of your choice when task activity happens in a project.", - "version": "0.1.7", - "minCoreVersion": "v0.11.2", + "version": "0.1.8", + "minCoreVersion": "v0.13.3", "permissions": ["db.read", "db.write", "events.subscribe"], "backend": { "allowedConfigKeys": ["ENCRYPTION_KEY", "PUBLIC_URL"],