PureYAML/.github/workflows/wasm.yml
Mihaela M ea31bb5864 chore(ci): split CI into per-workflow files with truthful badges
Rule 8.1 forbids one multi-job workflow fronted by several cosmetically
labeled badges that all resolve to the same whole-workflow status. Split
ci.yml into one workflow per concern (gates, macOS, Linux, Windows,
WASM, corpus), each with a unique name, and point each README badge at
its own workflow through the native per-workflow badge. The WASM
workflow notes in a header that it is a build gate, not a test gate
(Rule 8.3). Add a static MIT license badge linking to LICENSE
(Rule 8.2). Step contents are unchanged from the previous jobs.
2026-06-26 05:48:11 +02:00

39 lines
1.3 KiB
YAML

name: WASM
# WASM build gate (Rule 8.3): the WASI SDK compiles the package; it does not run
# the test suite. A green badge here means "compiles for WASM", not "tests pass".
on:
push:
branches: [main]
pull_request:
workflow_dispatch:
permissions:
contents: read
jobs:
wasm:
name: WASM
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Install Swift toolchain dependencies
run: |
sudo apt-get update
sudo apt-get install -y libcurl4-openssl-dev
- name: Install swiftly
run: |
curl -L https://download.swift.org/swiftly/linux/swiftly-$(uname -m).tar.gz > swiftly.tar.gz
tar zxf swiftly.tar.gz
./swiftly init --quiet-shell-followup --assume-yes --skip-install
- name: Install Swift 6.3.2 and Wasm SDK
run: |
. "${SWIFTLY_HOME_DIR:-$HOME/.local/share/swiftly}/env.sh"
swiftly install --use 6.3.2
swift sdk install https://download.swift.org/swift-6.3.2-release/wasm-sdk/swift-6.3.2-RELEASE/swift-6.3.2-RELEASE_wasm.artifactbundle.tar.gz --checksum a61f0584c93283589f8b2f42db05c1f9a182b506c2957271402992655591dd7c
- name: Build for WASM
run: |
. "${SWIFTLY_HOME_DIR:-$HOME/.local/share/swiftly}/env.sh"
bash scripts/check-wasm.sh