Skip to content

0.7.3

0.7.3 #24

Workflow file for this run

name: Publish
on:
push:
tags:
- "v*"
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-node@v6
with:
node-version-file: ".node-version"
- run: |
wget -P ${{ runner.temp }} https://github.com/tinygo-org/tinygo/releases/download/v0.40.1/tinygo_0.40.1_amd64.deb
yes | sudo dpkg -i ${{ runner.temp }}/tinygo_0.40.1_amd64.deb
- name: Build
run: npm run build
- name: Upload
uses: actions/upload-artifact@v6
with:
name: build
path: |
gofmt.js
gofmt.wasm
publish-npm:
if: startsWith(github.ref, 'refs/tags/v')
runs-on: ubuntu-latest
needs: build
permissions:
id-token: write
steps:
- uses: actions/checkout@v6
- uses: actions/download-artifact@v7
with:
name: build
- uses: actions/setup-node@v6
with:
node-version-file: ".node-version"
registry-url: "https://registry.npmjs.org"
- name: Publish
run: npm publish --provenance
publish-github:
if: startsWith(github.ref, 'refs/tags/v')
runs-on: ubuntu-latest
needs: build
permissions:
packages: write
steps:
- uses: actions/checkout@v6
- uses: actions/download-artifact@v7
with:
name: build
- uses: actions/setup-node@v6
with:
node-version-file: ".node-version"
registry-url: "https://npm.pkg.github.com"
- name: Publish
run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
publish-jsr:
if: startsWith(github.ref, 'refs/tags/v')
runs-on: ubuntu-latest
needs: build
permissions:
contents: read
id-token: write
steps:
- uses: actions/checkout@v6
- uses: actions/download-artifact@v7
with:
name: build
- uses: actions/setup-node@v6
with:
node-version-file: ".node-version"
- name: Publish
run: npx jsr publish
publish-github-release:
if: startsWith(github.ref, 'refs/tags/v')
runs-on: ubuntu-latest
needs: build
permissions:
contents: write
steps:
- uses: actions/checkout@v6
- uses: actions/download-artifact@v7
with:
name: build
- name: Package
run: npm pack
- name: Release
uses: softprops/action-gh-release@9d7c94cfd0a1f3ed45544c887983e9fa900f0564
with:
files: |
*.tgz
*.wasm