Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 16 additions & 26 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ on:
- 'v*'

jobs:
goreleaser:
release:
name: Release job for Scaleway-cli
runs-on: "${{ vars.RUNS_ON || 'ubuntu-latest' }}"
steps:
- name: Checkout
Expand All @@ -33,37 +34,26 @@ jobs:
go mod tidy
git diff --exit-code

- name: Run GoReleaser
uses: goreleaser/goreleaser-action@5daf1e915a5f0af01ddbcd89a43b8061ff4f1a89 # v7.2.2
with:
version: "${{ vars.GORELEASER_VERSION || '~> v2' }}"
args: release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

wasm:
runs-on: "${{ vars.RUNS_ON || 'ubuntu-latest' }}"
needs:
- goreleaser
steps:
# Checkout should always be before setup-go to ensure caching is working
- name: Checkout
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
fetch-depth: 1
- name: Install Go
uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0
with:
go-version: stable
- name: Install pnpm
- name: Install pnpm for wasm
uses: pnpm/action-setup@0e279bb959325dab635dd2c09392533439d90093 # v6.0.8
with:
package_json_file: "wasm/package.json"
- name: Build

- name: Build WebAssembly version
run: VERSION=${{ github.ref_name }} ./scripts/build-wasm.sh
- name: Configure package version

- name: Configure WebAssembly package version
working-directory: wasm
run: pnpm version ${{ github.ref_name }}

- name: Publish package
Comment thread
remyleone marked this conversation as resolved.
working-directory: wasm
run: pnpm publish --no-git-checks

- name: Run GoReleaser
uses: goreleaser/goreleaser-action@5daf1e915a5f0af01ddbcd89a43b8061ff4f1a89 # v7.2.2
with:
version: "${{ vars.GORELEASER_VERSION || '~> v2' }}"
args: release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Loading