Publish on JSR #1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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: Typecheck | |
run: | | |
deno check src/**.ts | |
- name: Test | |
run: | | |
deno task test | |
- name: Publish to JSR | |
run: deno publish |