File tree Expand file tree Collapse file tree 2 files changed +50
-0
lines changed Expand file tree Collapse file tree 2 files changed +50
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Publish WIT to registry
2+
3+ on :
4+ workflow_dispatch :
5+
6+ jobs :
7+ publish-wit :
8+ runs-on : ubuntu-latest
9+ permissions :
10+ id-token : write
11+ packages : write
12+ contents : write
13+
14+ steps :
15+ - name : Checkout repository
16+ uses : actions/checkout@v3
17+
18+ - name : Install cargo-binstall
19+ uses : cargo-bins/cargo-binstall
20+
21+ - name : Install wasm-tools
22+ shell : bash
23+ run : cargo binstall wasm-tools
24+
25+ - name : Install wkg
26+ shell : bash
27+ run : cargo binstall wkg
28+
29+ - name : Login to the GitHub registry
30+ uses : docker/login-action
31+ with :
32+ registry : ghcr.io
33+ username : ${{ github.actor }}
34+ password : ${{ secrets.REGISTRY_PAT }}
35+
36+ - name : Build and publish WIT package
37+ shell : bash
38+ run : ./scripts/build-and-publish-wit.sh
39+
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ # This script builds and publishes the spin:up WIT package
3+ # NOTE: The package name and version are inferred from the
4+ # encoded wasm binary.
5+ set -euo pipefail
6+
7+ # Build the package
8+ wasm-tools component wit wit/ -w -o spin_up_wit.wasm
9+
10+ # Publish to registry
11+ wkg publish --registry spinframework.dev spin_up_wit.wasm
You can’t perform that action at this time.
0 commit comments