Swap some more only to rules

This commit is contained in:
Marek Roszko 2023-05-06 08:20:56 -04:00
parent 49655ae742
commit b0c5993f93
5 changed files with 15 additions and 26 deletions

View File

@ -15,9 +15,9 @@ win64_build:
- build\windows\vcpkg_installed - build\windows\vcpkg_installed
- .vcpkgCache - .vcpkgCache
rules: rules:
- if: $CI_PROJECT_ROOT_NAMESPACE == "kicad" && $CI_COMMIT_REF_PROTECTED == "true"
- if: $CI_PIPELINE_SOURCE == "schedule" - if: $CI_PIPELINE_SOURCE == "schedule"
when: never when: never
- if: $CI_PROJECT_ROOT_NAMESPACE == "kicad" && $CI_COMMIT_REF_PROTECTED == "true"
script: script:
- C:\builder\build.ps1 -Env -Arch x64 - C:\builder\build.ps1 -Env -Arch x64
- $vcpkgCache=Join-Path -Path (Get-Location) -ChildPath ".vcpkgCache";$env:VCPKG_DEFAULT_BINARY_CACHE=$vcpkgCache;New-Item -ItemType Directory -Force -Path $vcpkgCache - $vcpkgCache=Join-Path -Path (Get-Location) -ChildPath ".vcpkgCache";$env:VCPKG_DEFAULT_BINARY_CACHE=$vcpkgCache;New-Item -ItemType Directory -Force -Path $vcpkgCache

View File

@ -40,11 +40,8 @@ Coverity:
- coverity - coverity
stage: build stage: build
image: registry.gitlab.com/kicad/kicad-ci/source_containers/master/fedora:37 image: registry.gitlab.com/kicad/kicad-ci/source_containers/master/fedora:37
only: rules:
refs: - if: $CI_PIPELINE_SOURCE == "schedule" && $SCHEDULED_JOB_NAME == "coverity"
- schedules
variables:
- $SCHEDULED_JOB_NAME == "coverity"
cache: cache:
key: coverity key: coverity
paths: paths:

View File

@ -3,6 +3,8 @@ build_doxygen_docker:
services: services:
- docker:dind - docker:dind
stage: build stage: build
rules:
- if: $CI_PIPELINE_SOURCE == "schedule" && $SCHEDULED_JOB_NAME == "doxygen"
tags: tags:
- docker - docker
before_script: before_script:
@ -11,8 +13,3 @@ build_doxygen_docker:
script: script:
- docker build -t "${CI_REGISTRY_IMAGE}/doxygen:$CI_COMMIT_BRANCH" -f ./doxygen/doxygen.Dockerfile . - docker build -t "${CI_REGISTRY_IMAGE}/doxygen:$CI_COMMIT_BRANCH" -f ./doxygen/doxygen.Dockerfile .
- docker push "${CI_REGISTRY_IMAGE}/doxygen:$CI_COMMIT_BRANCH" - docker push "${CI_REGISTRY_IMAGE}/doxygen:$CI_COMMIT_BRANCH"
only:
refs:
- schedules
variables:
- $SCHEDULED_JOB_NAME == "doxygen"

View File

@ -10,19 +10,14 @@ validate_linux_metadata:
# Due to bug https://github.com/hughsie/appstream-glib/issues/381, this doesn't think our description tag # Due to bug https://github.com/hughsie/appstream-glib/issues/381, this doesn't think our description tag
# is localized even though it actually is. # is localized even though it actually is.
allow_failure: true allow_failure: true
only: rules:
refs: - if: $CI_PIPELINE_SOURCE == "schedule"
- master when: never
- branches - if: $CI_PIPELINE_SOURCE == "push" || $CI_PIPELINE_SOURCE == "merge_request_event"
- merge_requests
- pushes
changes: changes:
# Only run if the resources, its tests, or the translations are updated
- resources/linux/**/* - resources/linux/**/*
- qa/resources/linux/**/* - qa/resources/linux/**/*
- translation/**/* - translation/**/*
except:
- schedules
# Only build the metadata files in this CI job # Only build the metadata files in this CI job
script: script:
- mkdir -p build/linux - mkdir -p build/linux

View File

@ -7,8 +7,8 @@
test_formatting: test_formatting:
stage: test stage: test
needs: [] needs: []
only: rules:
- merge_requests - if: $CI_PIPELINE_SOURCE == "merge_request_event"
allow_failure: true allow_failure: true
before_script: before_script:
# We must manually add the KiCad remote to ensure it is named sensibly # We must manually add the KiCad remote to ensure it is named sensibly