mirror of https://github.com/kdl-org/kdl.git
add KDL example file
This commit is contained in:
parent
a8f3ef3c9f
commit
be237e7d69
|
|
@ -0,0 +1,47 @@
|
|||
// This example is a GitHub Action if it used KDL syntax.
|
||||
// See .github/workflows/ci.yml for the file this was based on.
|
||||
name "CI"
|
||||
|
||||
on "push" "pull_request"
|
||||
|
||||
env {
|
||||
RUSTFLAGS "-Dwarnings"
|
||||
}
|
||||
|
||||
jobs {
|
||||
fmt_and_docs "Check fmt & build docs" {
|
||||
runs-on "ubuntu-latest"
|
||||
steps {
|
||||
step uses="actions/checkout@v1"
|
||||
step "Install Rust" uses="actions-rs/toolchain@v1" {
|
||||
profile "minimal"
|
||||
toolchain "stable"
|
||||
components "rustfmt"
|
||||
override true
|
||||
}
|
||||
step "rustfmt" run="cargo fmt --all -- --check"
|
||||
step "docs" run="cargo doc --no-deps"
|
||||
}
|
||||
}
|
||||
build_and_test "Build & Test" {
|
||||
runs-on "${{ matrix.os }}"
|
||||
strategy {
|
||||
matrix {
|
||||
rust "1.46.0" "stable"
|
||||
os "ubuntu-latest", "macOS-latest", "windows-latest"
|
||||
}
|
||||
}
|
||||
|
||||
steps {
|
||||
step uses="actions/checkout@v1"
|
||||
step "Install Rust" uses="actions-rs/toolchain@v1" {
|
||||
profile "minimal"
|
||||
toolchain "${{ matrix.rust }}"
|
||||
components "clippy"
|
||||
override true
|
||||
}
|
||||
step "Clippy" run="cargo clippy --all -- -D warnings"
|
||||
step "Run tests" run="cargo test --all --verbose"
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue