Skip to content

Instantly share code, notes, and snippets.

@karuna
Created January 6, 2019 15:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save karuna/160b5c8f0edabcd740c31ab8de9eb5e2 to your computer and use it in GitHub Desktop.
Save karuna/160b5c8f0edabcd740c31ab8de9eb5e2 to your computer and use it in GitHub Desktop.
image: 'rust:latest'
stages:
- test
- doc
- build
variables:
CARGO_HOME: $CI_PROJECT_DIR/cargo
APT_CACHE_DIR: $CI_PROJECT_DIR/apt
before_script:
- apt-get update -yq
- apt-get install -o dir::cache::archives="$APT_CACHE_DIR" -y {{ DEPENDENCIES }}
test:
stage: test
script:
- rustc --version
- cargo --version
- cargo test --verbose
pages:
stage: doc
script:
- cargo doc --no-deps
- mv target/doc public
- echo '<meta http-equiv="refresh" content="0; url={{ LIBRARY NAME }}">' > public/index.html
artifacts:
paths:
- public
only:
- master
cache:
paths:
- apt/
- cargo/
- target/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment