Skip to content

Publish on JSR

Publish on JSR #9

name: Publish on JSR
on:
workflow_dispatch:
jobs:
publish:
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write # The OIDC ID token is used for authentication with JSR.
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Deno
uses: denoland/setup-deno@v1
- name: Install Rust
run: |
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
export PATH="$HOME/.cargo/bin:$PATH"
rustc --version
cargo --version
- name: Install wasm-pack
run: |
curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
wasm-pack --version
- name: Install Deno
uses: denoland/setup-deno@v1
with:
deno-version: v1.x
- name: Build
run: |
deno task build --bypass-pkg-check --bypass-rs-check
- name: Apply Patch
run: |
sed -i "s/!:/:/g" pkg/si_img.d.ts
- name: Typecheck
run: |
deno check src/**.ts
- name: Test
run: |
deno task test
- name: Publish to JSR
run: deno publish