Skip to content

Commit

Permalink
Add basic CI conf (bytecodealliance#3)
Browse files Browse the repository at this point in the history
* Add basic CI conf

* Pull in submodules in Rustfmt job

* Exclude WASI from workspace; fix name clash in memory crate

* Refactor CI conf
  • Loading branch information
kubkon authored Feb 3, 2020
1 parent 3d428b8 commit e6cec04
Show file tree
Hide file tree
Showing 3 changed files with 67 additions and 2 deletions.
61 changes: 61 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: CI

on:
push:
branches:
- master
pull_request:

jobs:
rustfmt:
name: Rustfmt
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
with:
submodules: true
- name: Install Rust
run: |
rustup update stable
rustup default stable
rustup component add rustfmt
- name: Cargo fmt
run: cargo fmt --all -- --check

build:
name: Build
runs-on: ${{ matrix.os }}-latest
strategy:
matrix:
os: [ubuntu, macOS, windows]

steps:
- uses: actions/checkout@v1
with:
submodules: true
- name: Install Rust
shell: bash
run: |
rustup update stable
rustup default stable
- name: Build
run: cargo build --all --release -vv

test:
name: Test
runs-on: ${{ matrix.os }}-latest
strategy:
matrix:
os: [ubuntu, macOS, windows]

steps:
- uses: actions/checkout@v1
with:
submodules: true
- name: Install Rust
shell: bash
run: |
rustup update stable
rustup default stable
- name: Test
run: cargo test --all
6 changes: 5 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,8 @@ generate = { path = "crates/generate" }
memory = { path = "crates/memory" }

[workspace]
members = ["crates/generate"]
members = [
"crates/generate",
"crates/memory"
]
exclude = ["crates/WASI"]
2 changes: 1 addition & 1 deletion crates/memory/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ mod guest_type;
mod memory;
mod region;

pub use self::memory::{GuestMemory, GuestPtr, GuestPtrMut, GuestRef, GuestRefMut};
pub use error::GuestError;
pub use guest_type::{GuestErrorType, GuestType, GuestTypeClone, GuestTypeCopy, GuestTypePtr};
pub use memory::{GuestMemory, GuestPtr, GuestPtrMut, GuestRef, GuestRefMut};
pub use region::Region;

0 comments on commit e6cec04

Please sign in to comment.