Summer/.gitlab-ci.yml

37 lines
663 B
YAML
Raw Permalink Normal View History

2020-02-29 22:45:04 +01:00
# This file is a template, and might need editing before it works on your project.
# Official language image. Look for the different tagged releases at:
# https://hub.docker.com/r/library/rust/tags/
image: "rust:latest"
2020-02-29 22:56:14 +01:00
stages:
- test
- build
2020-02-29 22:45:04 +01:00
2020-02-29 22:56:14 +01:00
# Use cargo to test the project
test:
stage: test
2020-02-29 22:45:04 +01:00
script:
- cargo test --all --verbose
cache:
2020-02-29 22:56:14 +01:00
key: cargo_cache
2020-02-29 22:45:04 +01:00
paths:
- target/
2020-02-29 22:56:14 +01:00
build:
stage: build
only:
- master
- tags
script:
- cargo build --release
cache:
key: cargo_cache
paths:
- target/
artifacts:
expire_in: 30 days
paths:
- target/release/summer
- target/release/summer.*