mirror of
https://gitlab.com/MisterBiggs/brain-quartz.git
synced 2025-06-15 17:26:40 +00:00
43 lines
892 B
YAML
43 lines
892 B
YAML
stages:
|
|
- build
|
|
- deploy
|
|
|
|
variables:
|
|
GIT_SUBMODULE_STRATEGY: recursive
|
|
GIT_SUBMODULE_FORCE_HTTPS: "true"
|
|
|
|
image: node:22
|
|
cache: # Cache modules in between jobs
|
|
key: $CI_COMMIT_REF_SLUG
|
|
paths:
|
|
- .npm/
|
|
|
|
build:
|
|
stage: build
|
|
rules:
|
|
- if: '$CI_COMMIT_REF_NAME == "v4"'
|
|
before_script:
|
|
- git config --global url."https://gitlab-ci-token:${CI_JOB_TOKEN}@gitlab.com/".insteadOf "git@gitlab.com:"
|
|
- git submodule sync --recursive
|
|
- git submodule update --init --recursive --remote
|
|
- hash -r
|
|
- npm ci --cache .npm --prefer-offline
|
|
script:
|
|
- npx quartz build
|
|
artifacts:
|
|
paths:
|
|
- public
|
|
# I don't think I need this with my own runners
|
|
# tags:
|
|
# - gitlab-org-docker
|
|
|
|
pages:
|
|
stage: deploy
|
|
rules:
|
|
- if: '$CI_COMMIT_REF_NAME == "v4"'
|
|
script:
|
|
- echo "Deploying to GitLab Pages..."
|
|
artifacts:
|
|
paths:
|
|
- public
|