-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Rajat Jindal <[email protected]>
- Loading branch information
1 parent
1243d8e
commit cc713ea
Showing
2 changed files
with
29 additions
and
52 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,26 @@ | ||
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json | ||
name: Build | ||
on: | ||
push: | ||
branches: [main] | ||
pull_request: | ||
branches: ["main"] | ||
|
||
jobs: | ||
test: | ||
name: Test | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Setup TinyGo | ||
uses: rajatjindal/setup-actions/[email protected] | ||
id: setup | ||
with: | ||
version: "v0.27.0" | ||
version: "v0.30.0" | ||
|
||
- name: Install Spin canary | ||
uses: engineerd/[email protected] | ||
- name: Setup Spin | ||
uses: fermyon/actions/spin/setup@v1 | ||
with: | ||
name: "spin" | ||
url: "https://github.com/fermyon/spin/releases/download/canary/spin-canary-linux-amd64.tar.gz" | ||
pathInArchive: "spin" | ||
version: "canary" | ||
|
||
- name: Build application | ||
shell: bash | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,52 +22,30 @@ jobs: | |
name: Build and release assets | ||
runs-on: "ubuntu-latest" | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Setup Spin | ||
uses: fermyon/actions/spin/setup@v1 | ||
with: | ||
version: "canary" | ||
|
||
- name: Install nodejs | ||
uses: actions/setup-node@v3 | ||
- name: "Install TinyGo" | ||
uses: rajatjindal/setup-actions/[email protected] | ||
with: | ||
node-version: 16 | ||
version: 'v0.30.0' | ||
|
||
- name: "Build" | ||
run: spin build | ||
|
||
- name: Install NPM dependencies for explorer | ||
shell: bash | ||
- name: generate checksums | ||
run: | | ||
cd explorer | ||
npm install - | ||
sha256sum explorer/main.wasm > checksums-${{ env.RELEASE_VERSION }}.txt | ||
- name: Install Spin canary | ||
uses: engineerd/[email protected] | ||
- name: Create release | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
name: "spin" | ||
url: "https://github.com/fermyon/spin/releases/download/canary/spin-canary-linux-amd64.tar.gz" | ||
pathInArchive: "spin" | ||
|
||
# Currently, the explorer is built with the dev branch of TinyGo. | ||
# Until there is a release of TinyGo, the binary is added manually | ||
# to the GitHub release. | ||
# | ||
# - name: Install the Spin JS plugin | ||
# shell: bash | ||
# run: | | ||
# spin plugin update | ||
# spin plugin install js2wasm -y | ||
# | ||
# - name: Build application | ||
# shell: bash | ||
# run: | | ||
# spin build | ||
# | ||
# - name: set the release version (tag) | ||
# run: echo "RELEASE_VERSION=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_ENV | ||
# | ||
# - name: generate checksums | ||
# run: | | ||
# sha256sum explorer/target/spin-kv-explorer.wasm > checksums-${{ env.RELEASE_VERSION }}.txt | ||
# - name: Create release | ||
# uses: softprops/action-gh-release@v1 | ||
# with: | ||
# fail_on_unmatched_files: true | ||
# generate_release_notes: true | ||
# files: | | ||
# explorer/target/spin-kv-explorer.wasm | ||
# checksums-${{ env.RELEASE_VERSION }}.txt | ||
fail_on_unmatched_files: true | ||
generate_release_notes: true | ||
files: | | ||
explorer/main.wasm | ||
checksums-${{ env.RELEASE_VERSION }}.txt |