From 09157bf9d66affba53987d4d5219c20f0d5bf491 Mon Sep 17 00:00:00 2001 From: Jake Howard Date: Fri, 9 Oct 2020 19:42:11 +0100 Subject: [PATCH] Add GitLab CI file --- .gitlab-ci.yml | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 .gitlab-ci.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..53b6ed9 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,30 @@ +image: "node:lts-slim" + +variables: + HUGO_VERSION: "0.73.0" + +cache: + key: ${CI_COMMIT_REF_SLUG} + paths: + - .npm + - .cache + +before_script: + - wget https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_extended_${HUGO_VERSION}_Linux-64bit.deb -O /tmp/hugo.deb + - dpkg -i /tmp/hugo.deb + - npm ci --cache .npm --prefer-offline --production + +test: + stage: test + script: + - ./scripts/test.sh + +pages: + stage: deploy + script: + - ./scripts/release.sh + artifacts: + paths: + - public + only: + - master