ruwuma/ruma-client/.builds/nightly.yml
Jonas Platte 3a6bdd63bd Add 'ruma-client/' from commit 'fab0ef566f143c1926bff4af4a0a4751379eff1f'
git-subtree-dir: ruma-client
git-subtree-mainline: c4558774be98863015c51e0ec8f26b3fe3d4a103
git-subtree-split: fab0ef566f143c1926bff4af4a0a4751379eff1f
2020-08-10 23:49:55 +02:00

33 lines
909 B
YAML

image: archlinux
packages:
- rustup
sources:
- https://github.com/ruma/ruma-client
tasks:
- rustup: |
rustup toolchain install nightly --profile minimal
rustup default nightly
# Try installing rustfmt & clippy for nightly, but don't fail the build
# if they are not available
rustup component add rustfmt || true
rustup component add clippy || true
- test: |
cd ruma-client
# We don't want the build to stop on individual failure of independent
# tools, so capture tool exit codes and set the task exit code manually
set +e
if ( rustup component list | grep -q rustfmt ); then
cargo fmt -- --check
fi
fmt_exit=$?
if ( rustup component list | grep -q clippy ); then
cargo clippy --all-targets --all-features -- -D warnings
fi
clippy_exit=$?
exit $(( $fmt_exit || $clippy_exit ))