markdowny/.gitlab-ci.yml
2021-02-03 23:38:44 -06:00

23 lines
747 B
YAML

image: node:latest
stages:
- publish
publish:
stage: publish
script:
# Remove the references so it builds cleanly.
- apt-get update
- apt-get install jq -y
- "cat tsconfig.json | jq 'del(.references)' > a && mv a tsconfig.json"
# Make sure the commits are clean
- yarn install --frozen-lockfile
- if [ $CI_BUILD_BEFORE_SHA == "0000000000000000000000000000000000000000" ]; then npx commitlint --to=HEAD; else npx commitlint --from=$CI_BUILD_BEFORE_SHA; fi
# Build the project
- yarn run build
# Perform the automatic release process
- npx semantic-release --repository-url=https://oauth2:$GITLAB_TOKEN@gitlab.com/mfgames-writing/markdowny.git