podcasts/.gitlab-ci.yml
Jordan Petridis 9beea21a4f
Code cleanup.
Converted rest of .clone() s on ref pointer to use the macro instead.
Stopped ignoring clippy clone_on_ref_pointer warnings since there shouldn't
be any, anymore.
2017-10-23 07:37:07 +03:00

62 lines
1.9 KiB
YAML

# Optional: Install a C compiler, cmake and git into the container.
# You will often need this when you (or any of your dependencies) depends on C code.
before_script:
- apt-get update -yqq
- apt-get install -yqq --no-install-recommends build-essential
- apt-get install -yqq --no-install-recommends libgtk-3-dev
# kcov
# - apt-get install -y libcurl4-openssl-dev libelf-dev libdw-dev cmake gcc binutils-dev libiberty-dev
# variables:
# RUSTFLAGS: "-C link-dead-code"
test:stable:
# Stable img
# https://hub.docker.com/_/rust/
image: "rust"
script:
- rustc --version && cargo --version # Print version info for debugging
- cargo build --all
- cargo test --all --verbose
# - cargo test --all --verbose --jobs 1
test:nightly:
# Nightly
# https://hub.docker.com/r/rustlang/rust/
image: "rustlang/rust:nightly"
script:
- rustc --version && cargo --version # Print version info for debugging
- cargo build --all
- cargo test --all --verbose
# - cargo test --all --verbose --jobs 1
# - cargo bench
# Configure and run rustfmt on nightly
# Exits and builds fails if on bad format
test:rustfmt:
image: "rustlang/rust:nightly"
before_script:
- apt-get update -yqq
- apt-get install -yqq --no-install-recommends build-essential
- apt-get install -yqq --no-install-recommends build-essential libgtk-3-dev
- export PATH="$PATH:$HOME/.cargo/bin"
- which rustfmt || cargo install rustfmt-nightly
script:
- rustc --version && cargo --version
- cargo fmt --all -- --write-mode=diff
# Configure and run clippy on nightly
# Only fails on errors atm.
test:clippy:
image: "rustlang/rust:nightly"
before_script:
- apt-get update -yqq
- apt-get install -yqq --no-install-recommends build-essential
- apt-get install -yqq --no-install-recommends build-essential libgtk-3-dev
- export PATH="$PATH:$HOME/.cargo/bin"
- which rustfmt || cargo install clippy
script:
- rustc --version && cargo --version
- cargo clippy --all