Commit 8d1f6bd6 authored by Ruben ten Hove's avatar Ruben ten Hove
Browse files

feat: run only useful pipelines

parent 75736a2c
Loading
Loading
Loading
Loading
+11 −3
Original line number Diff line number Diff line
---
workflow:
  rules:
    - if: $CI_MERGE_REQUEST_IID
      when: never
    - when: always
    # If in a Draft Merge Request, run manually
    - if: $CI_MERGE_REQUEST_TITLE =~ /(?i)-draft/
      when: manual
    # Only run when a new version tag is pushed
    - if: $CI_COMMIT_TAG =~ /^v[0-9]+(\.[0-9]+){2}(.*)$/
    # Run on merge requests, if not in Draft (first rule)
    - if: $CI_PIPELINE_SOURCE == "merge_request_event"
    # Run on the default branch, if this was not a semantic-release commit
    - if:
        '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~
        /^chore\(release\)/'