-
Notifications
You must be signed in to change notification settings - Fork 6
/
.gitlab-ci.yml
59 lines (54 loc) · 1.22 KB
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# Template project: https://gitlab.com/pages/jekyll
# Docs: https://docs.gitlab.com/ce/pages/
image: ruby:2.4.3
variables:
GIT_DEPTH: 1
GIT_STRATEGY: fetch
JEKYLL_ENV: production
BUNDLE_PATH: vendor/bundle
NOKOGIRI_USE_SYSTEM_LIBRARIES: 1
LC_ALL: C.UTF-8
.before_script_bundle: &before_script_bundle
- bundle install --deployment
- 'echo "url: https://"${CI_PROJECT_NAME} >> _config.${JEKYLL_ENV}.yml'
test:
stage: test
variables:
JEKYLL_ENV: test
before_script: *before_script_bundle
script:
- .ci/fast_build.sh
- bundle exec htmlproofer ./public --empty-alt-ignore --assume-extension --disable-external --checks-to-ignore=LinkCheck,ImageCheck --check-html
cache:
paths:
- vendor
- public
except:
- master
check_code:
stage: test
variables:
GIT_STRATEGY: clone
image: python:slim
script:
- pip install coala-bears
- coala --ci
except:
- master
pages:
stage: deploy
variables:
# Simulate the netlify production flag used by .ci/fast_build.sh
CONTEXT: production
before_script: *before_script_bundle
script:
- .ci/fast_build.sh
cache:
paths:
- vendor
- public
artifacts:
paths:
- public
only:
- master