yandere_fe/.gitlab-ci.yml

73 lines
1.7 KiB
YAML
Raw Normal View History

2016-11-22 04:49:53 -08:00
# This file is a template, and might need editing before it works on your project.
# Official framework image. Look for the different tagged releases at:
# https://hub.docker.com/r/library/node/tags/
2022-07-17 20:48:11 -07:00
image: node:16
2016-11-22 04:49:53 -08:00
2017-03-01 11:42:45 -08:00
stages:
2023-04-28 15:12:38 -07:00
- check-changelog
2017-03-08 23:58:17 -08:00
- lint
2017-03-01 11:42:45 -08:00
- build
- test
- deploy
2017-03-01 11:42:45 -08:00
# https://git.pleroma.social/help/ci/yaml/workflow.md#switch-between-branch-pipelines-and-merge-request-pipelines
workflow:
rules:
- if: $CI_PIPELINE_SOURCE == "merge_request_event"
- if: $CI_COMMIT_BRANCH && $CI_OPEN_MERGE_REQUESTS
when: never
- if: $CI_COMMIT_BRANCH
2023-04-28 15:12:38 -07:00
check-changelog:
stage: check-changelog
image: alpine
rules:
- if: $CI_MERGE_REQUEST_SOURCE_PROJECT_PATH == 'pleroma/pleroma-fe' && $CI_MERGE_REQUEST_SOURCE_BRANCH_NAME =~ /^renovate/
when: never
- if: $CI_MERGE_REQUEST_SOURCE_PROJECT_PATH == 'pleroma/pleroma-fe' && $CI_MERGE_REQUEST_SOURCE_BRANCH_NAME == 'weblate'
when: never
- if: $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "develop"
before_script: ''
after_script: ''
cache: {}
script:
- apk add git
- sh ./tools/check-changelog
2017-03-08 23:58:17 -08:00
lint:
stage: lint
script:
- yarn
- npm run lint
- npm run stylelint
2017-03-08 23:58:17 -08:00
2016-11-22 04:49:53 -08:00
test:
2017-03-01 11:46:07 -08:00
stage: test
2019-04-28 10:14:35 -07:00
variables:
APT_CACHE_DIR: apt-cache
2016-11-22 04:49:53 -08:00
script:
2019-04-28 10:14:35 -07:00
- mkdir -pv $APT_CACHE_DIR && apt-get -qq update
- apt install firefox-esr -y --no-install-recommends
- firefox --version
2017-02-16 04:48:36 -08:00
- yarn
2019-11-14 13:46:19 -08:00
- yarn unit
2017-02-18 12:26:17 -08:00
2016-11-22 04:49:53 -08:00
build:
2017-03-01 11:46:07 -08:00
stage: build
2016-11-22 04:49:53 -08:00
script:
2017-02-16 04:48:36 -08:00
- yarn
2016-11-22 05:04:54 -08:00
- npm run build
2016-12-08 06:55:12 -08:00
artifacts:
paths:
- dist/
docs-deploy:
stage: deploy
image: alpine:latest
only:
- develop@pleroma/pleroma-fe
before_script:
- apk add curl
script:
- curl -X POST -F"token=$DOCS_PIPELINE_TRIGGER" -F'ref=master' https://git.pleroma.social/api/v4/projects/673/trigger/pipeline