mirror of
https://gitlab.freedesktop.org/emersion/libdisplay-info.git
synced 2024-11-16 19:48:30 +01:00
73b763d6b4
See https://docs.gitlab.com/ee/ci/yaml/#rules Signed-off-by: Simon Ser <contact@emersion.fr>
50 lines
1.2 KiB
YAML
50 lines
1.2 KiB
YAML
.templates_sha: &templates_sha 3e66ea37e5672bb8f48e3056ba92915b5fc5b888
|
|
|
|
include:
|
|
- project: 'freedesktop/ci-templates'
|
|
ref: *templates_sha
|
|
file: '/templates/ci-fairy.yml'
|
|
- project: 'freedesktop/ci-templates'
|
|
ref: *templates_sha
|
|
file: '/templates/alpine.yml'
|
|
|
|
variables:
|
|
FDO_UPSTREAM_REPO: 'emersion/libdisplay-info'
|
|
FDO_DISTRIBUTION_TAG: '2022-03-24.2'
|
|
|
|
stages:
|
|
- "Contribution checks"
|
|
- "Prepare container"
|
|
- "Build and test"
|
|
|
|
check-mr:
|
|
extends: .fdo.ci-fairy
|
|
stage: "Contribution checks"
|
|
script:
|
|
- ci-fairy check-commits --signed-off-by
|
|
- ci-fairy check-merge-request --require-allow-collaboration
|
|
rules:
|
|
- if: '$CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "main"'
|
|
when: always
|
|
- when: never
|
|
|
|
prepare-container:
|
|
extends: .fdo.container-build@alpine@x86_64
|
|
stage: "Prepare container"
|
|
variables:
|
|
FDO_DISTRIBUTION_PACKAGES: 'build-base meson'
|
|
rules:
|
|
- when: on_success
|
|
|
|
build:
|
|
extends: .fdo.distribution-image@alpine
|
|
stage: "Build and test"
|
|
script:
|
|
- meson build/ -Dwerror=true
|
|
- ninja -C build/
|
|
- ninja -C build/ test
|
|
artifacts:
|
|
paths:
|
|
- build/meson-logs/
|
|
rules:
|
|
- when: on_success
|