2018-08-26 06:56:15 +00:00
|
|
|
image: dmoonfire/mfgames-writing-js:1.1.1
|
|
|
|
|
|
|
|
stages:
|
|
|
|
- publish
|
|
|
|
|
|
|
|
publish:
|
|
|
|
stage: publish
|
|
|
|
tags:
|
|
|
|
- docker
|
|
|
|
script:
|
|
|
|
# Install the basic requirements including the free fonts.
|
|
|
|
- npm ci
|
|
|
|
|
|
|
|
# Verify that the commits are good.
|
2019-04-15 04:18:14 +00:00
|
|
|
- npx commitlint --from=$CI_BUILD_BEFORE_SHA
|
2018-08-26 06:56:15 +00:00
|
|
|
|
|
|
|
# We need the covers for generation.
|
|
|
|
- mkdir -p build/repos
|
|
|
|
- git clone https://oauth2:$fedranAccessKey@gitlab.com/fedran/fedran-covers.git build/repos/fedran-covers
|
|
|
|
|
|
|
|
# Trigger the release if needed.
|
|
|
|
- npx semantic-release
|
|
|
|
|
2019-04-15 03:44:44 +00:00
|
|
|
# Build the files.
|
2018-08-26 06:56:15 +00:00
|
|
|
- npm run build
|
|
|
|
|
|
|
|
# Trigger the Fedran website to rebuild.
|
|
|
|
- "curl -X POST -F token=$fedranAccessKey -F ref=master https://gitlab.com/api/v4/projects/4027285/trigger/pipeline"
|
|
|
|
|
|
|
|
artifacts:
|
|
|
|
expire_in: 1 week
|
|
|
|
paths:
|
|
|
|
- "*.pdf"
|
|
|
|
- "*.epub"
|
|
|
|
- "*.mobi"
|
|
|
|
- "*.docx"
|
|
|
|
- "*.html"
|