Skip to content

Commit

Permalink
Move wasm build into the release job (#38)
Browse files Browse the repository at this point in the history
* Move wasm build into the release job

* Adds a changeset

* Update go version
  • Loading branch information
matthewp authored Oct 7, 2021
1 parent 73f8bf5 commit c4ed69e
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 16 deletions.
5 changes: 5 additions & 0 deletions .changeset/olive-suns-prove.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@astrojs/compiler": patch
---

Includes the wasm binary in the npm package
27 changes: 11 additions & 16 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,16 @@ on:
- main

jobs:
build-wasm:
release:
name: Changelog
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.16
go-version: 1.17

- name: Get tinygo runtime
run: |
Expand All @@ -27,12 +28,6 @@ jobs:
cp -R . /home/runner/go/src/github.com/snowpackjs/astro/
tinygo build -o astro.wasm -target wasm ./cmd/astro-wasm/astro-wasm.go
release:
name: Changelog
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- name: Set up Node.js 14.x
uses: actions/setup-node@v2
with:
Expand All @@ -52,11 +47,11 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

- name: Send a Discord notification if a publish happens
if: steps.changesets.outputs.published == 'true'
id: discord-notification
env:
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}
uses: Ilshidur/action-discord@0.3.2
with:
args: 'A new release of astro-compiler-next just went out! [Release notes →](<https://github.com/snowpackjs/astro-compiler-next/releases/>)'
# - name: Send a Discord notification if a publish happens
# if: steps.changesets.outputs.published == 'true'
# id: discord-notification
# env:
# DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}
# uses: Ilshidur/action-discord@0.3.2
# with:
# args: 'A new release of astro-compiler-next just went out! [Release notes →](<https://github.com/snowpackjs/astro-compiler-next/releases/>)'

0 comments on commit c4ed69e

Please sign in to comment.