From e470f060e3a23a1bab842e5328354b4727dfcfe8 Mon Sep 17 00:00:00 2001 From: Dominic Date: Wed, 6 May 2020 15:58:11 +0200 Subject: [PATCH] deploy documentation as gitlab pages --- .gitlab-ci.yml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index c50b7f5..128171b 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,6 +1,7 @@ stages: - test + - build - publish variables: @@ -43,6 +44,36 @@ readme: - cargo readme -t README.tpl >README.md.new - diff README.md README.md.new +doc: + stage: build + image: msrd0/rust:alpine + before_script: + - cargo -V + script: + - cargo doc --all-features + - echo 'The documentation is located here' >target/doc/index.html + artifacts: + paths: + - target/doc/ + cache: + paths: + - cargo/ + - target/ + only: + - master + +pages: + stage: publish + image: busybox + script: + - mv target/doc public + - mv tarpaulin-report.html public/coverage.html + artifacts: + paths: + - public + only: + - master + publish: stage: publish image: msrd0/rust:alpine