forked from kcl-lang/kcl
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: add wasm target unit test and release (kcl-lang#1380)
Signed-off-by: peefy <[email protected]>
- Loading branch information
Showing
6 changed files
with
44 additions
and
7 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 |
---|---|---|
@@ -0,0 +1,29 @@ | ||
name: build-and-test-wasm | ||
on: ["push", "pull_request"] | ||
jobs: | ||
build-and-test: | ||
# Ref: https://github.com/actions/runner-images/tree/main/images/linux | ||
name: Test | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Check out code | ||
uses: actions/checkout@v3 | ||
with: | ||
submodules: "true" | ||
|
||
- name: Install rust nightly toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: 1.76 | ||
override: true | ||
components: clippy, rustfmt | ||
|
||
- name: Unit test | ||
working-directory: ./kclvm | ||
run: rustup target add wasm32-wasi && make build-wasm | ||
shell: bash | ||
|
||
- uses: actions/upload-artifact@v3 | ||
with: | ||
name: kcl-wasm | ||
path: kclvm/target/wasm32-wasi/release/kclvm_cli_cdylib.wasm |
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
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
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
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,4 +1,5 @@ | ||
pub mod arguments; | ||
#[cfg(not(target_arch = "wasm32"))] | ||
pub mod client; | ||
pub mod toolchain; | ||
|
||
|
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