Compare commits
2 commits
2d5b8247b2
...
29df35b196
Author | SHA1 | Date | |
---|---|---|---|
|
29df35b196 | ||
21c8f0883a |
1 changed files with 1 additions and 53 deletions
|
@ -1,5 +1,5 @@
|
||||||
variables:
|
variables:
|
||||||
- &rust_image "docker.io/rust:1.79.0"
|
- &rust_image "docker.io/rust:1.80.0"
|
||||||
- &slow_check_paths
|
- &slow_check_paths
|
||||||
- path:
|
- path:
|
||||||
# rust source code
|
# rust source code
|
||||||
|
@ -14,22 +14,11 @@ variables:
|
||||||
- ".woodpecker.yml"
|
- ".woodpecker.yml"
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
|
|
||||||
toml_fmt:
|
toml_fmt:
|
||||||
image: docker.io/tamasfe/taplo:0.9.2
|
image: docker.io/tamasfe/taplo:0.9.2
|
||||||
commands:
|
commands:
|
||||||
- taplo format --check
|
- taplo format --check
|
||||||
|
|
||||||
|
|
||||||
cargo_fmt:
|
|
||||||
image: docker.io/rustlang/rust:nightly
|
|
||||||
environment:
|
|
||||||
# store cargo data in repo folder so that it gets cached between steps
|
|
||||||
CARGO_HOME: .cargo_home
|
|
||||||
commands:
|
|
||||||
- rustup component add rustfmt
|
|
||||||
- cargo fmt --check
|
|
||||||
|
|
||||||
cargo_machete:
|
cargo_machete:
|
||||||
image: *rust_image
|
image: *rust_image
|
||||||
commands:
|
commands:
|
||||||
|
@ -47,47 +36,6 @@ steps:
|
||||||
- IGNORED=$(git ls-files --cached -i --exclude-standard)
|
- IGNORED=$(git ls-files --cached -i --exclude-standard)
|
||||||
- if [[ "$IGNORED" ]]; then echo "Ignored files present:\n$IGNORED\n"; exit 1; fi
|
- if [[ "$IGNORED" ]]; then echo "Ignored files present:\n$IGNORED\n"; exit 1; fi
|
||||||
|
|
||||||
check:
|
|
||||||
image: *rust_image
|
|
||||||
environment:
|
|
||||||
CARGO_HOME: .cargo_home
|
|
||||||
commands:
|
|
||||||
- cargo check
|
|
||||||
when: *slow_check_paths
|
|
||||||
|
|
||||||
cargo_clippy:
|
|
||||||
image: *rust_image
|
|
||||||
environment:
|
|
||||||
CARGO_HOME: .cargo_home
|
|
||||||
commands:
|
|
||||||
- rustup component add clippy
|
|
||||||
- cargo clippy --tests --all-targets -- -D warnings
|
|
||||||
when: *slow_check_paths
|
|
||||||
|
|
||||||
cargo_build:
|
|
||||||
image: *rust_image
|
|
||||||
environment:
|
|
||||||
CARGO_HOME: .cargo_home
|
|
||||||
commands:
|
|
||||||
- cargo build
|
|
||||||
- mv target/debug/skip target/skip
|
|
||||||
when: *slow_check_paths
|
|
||||||
|
|
||||||
cargo_test:
|
|
||||||
image: *rust_image
|
|
||||||
environment:
|
|
||||||
RUST_BACKTRACE: "1"
|
|
||||||
CARGO_HOME: .cargo_home
|
|
||||||
commands:
|
|
||||||
- cargo test --no-fail-fast
|
|
||||||
when: *slow_check_paths
|
|
||||||
|
|
||||||
integration_test:
|
|
||||||
image: *rust_image
|
|
||||||
commands:
|
|
||||||
- ./test.sh
|
|
||||||
when: *slow_check_paths
|
|
||||||
|
|
||||||
publish_to_crates_io:
|
publish_to_crates_io:
|
||||||
image: *rust_image
|
image: *rust_image
|
||||||
commands:
|
commands:
|
||||||
|
|
Loading…
Reference in a new issue