mirror of
https://github.com/sudoxnym/fdroiddata.git
synced 2026-07-13 17:51:43 +00:00
add merge request pipelines flag
This commit is contained in:
parent
80ec8d24f6
commit
c964c66451
1 changed files with 11 additions and 6 deletions
|
|
@ -1,12 +1,12 @@
|
||||||
include:
|
include:
|
||||||
- template: Security/SAST.gitlab-ci.yml
|
- template: Security/SAST.gitlab-ci.yml
|
||||||
|
|
||||||
workflow:
|
workflow:
|
||||||
rules:
|
rules:
|
||||||
# required to enable merge request pipelines: https://docs.gitlab.com/ee/ci/pipelines/merge_request_pipelines.html#prerequisites
|
# required to enable merge request pipelines: https://docs.gitlab.com/ee/ci/pipelines/merge_request_pipelines.html#prerequisites
|
||||||
- if: $CI_PIPELINE_SOURCE == "merge_request_event"
|
- if: $CI_PIPELINE_SOURCE == "merge_request_event" && $CI_ENABLE_MERGE_REQUEST_PIPELINES != "false"
|
||||||
# to prevent duplicate pipelines in MRs: https://docs.gitlab.com/ee/ci/yaml/workflow.html#switch-between-branch-pipelines-and-merge-request-pipelines
|
# to prevent duplicate pipelines in MRs: https://docs.gitlab.com/ee/ci/yaml/workflow.html#switch-between-branch-pipelines-and-merge-request-pipelines
|
||||||
- if: $CI_COMMIT_BRANCH && $CI_OPEN_MERGE_REQUESTS
|
- if: $CI_COMMIT_BRANCH && $CI_OPEN_MERGE_REQUESTS && $CI_PIPELINE_SOURCE == "push" && $CI_ENABLE_MERGE_REQUEST_PIPELINES != "false"
|
||||||
when: never
|
when: never
|
||||||
- if: $CI_COMMIT_TAG
|
- if: $CI_COMMIT_TAG
|
||||||
- if: $CI_COMMIT_BRANCH
|
- if: $CI_COMMIT_BRANCH
|
||||||
|
|
@ -21,8 +21,13 @@ stages:
|
||||||
variables:
|
variables:
|
||||||
pip: pip3 --timeout 100 --retries 10
|
pip: pip3 --timeout 100 --retries 10
|
||||||
|
|
||||||
# needs lots of git history since it has to compare the merge request to current master
|
GIT_DEPTH:
|
||||||
GIT_DEPTH: "5000"
|
description: needs lots of git history since it has to compare the merge request to current master
|
||||||
|
value: "5000"
|
||||||
|
|
||||||
|
CI_ENABLE_MERGE_REQUEST_PIPELINES:
|
||||||
|
description: push with `git push -o ci.variable="CI_ENABLE_MERGE_REQUEST_PIPELINES=false"` to disable merge request pipelines (e.g., to use self-hosted runners)
|
||||||
|
value: "true"
|
||||||
|
|
||||||
.install_fdroid_server: &install_fdroid_server
|
.install_fdroid_server: &install_fdroid_server
|
||||||
- rm -rf $fdroidserver
|
- rm -rf $fdroidserver
|
||||||
|
|
@ -79,7 +84,7 @@ variables:
|
||||||
rules: &app_verification_rules
|
rules: &app_verification_rules
|
||||||
- if: $CI_PIPELINE_SOURCE == "pipeline" || $CI_PIPELINE_SOURCE == "schedule" || $CI_PIPELINE_SOURCE == "trigger"
|
- if: $CI_PIPELINE_SOURCE == "pipeline" || $CI_PIPELINE_SOURCE == "schedule" || $CI_PIPELINE_SOURCE == "trigger"
|
||||||
when: never
|
when: never
|
||||||
- if: $CI_COMMIT_BRANCH && $CI_OPEN_MERGE_REQUESTS
|
- if: $CI_COMMIT_BRANCH && $CI_OPEN_MERGE_REQUESTS && $CI_ENABLE_MERGE_REQUEST_PIPELINES != "false"
|
||||||
when: never
|
when: never
|
||||||
- if: $CI_PIPELINE_SOURCE == "merge_request_event"
|
- if: $CI_PIPELINE_SOURCE == "merge_request_event"
|
||||||
# only works for merge request pipelines: https://docs.gitlab.com/ee/ci/jobs/job_control.html#jobs-or-pipelines-run-unexpectedly-when-using-changes
|
# only works for merge request pipelines: https://docs.gitlab.com/ee/ci/jobs/job_control.html#jobs-or-pipelines-run-unexpectedly-when-using-changes
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue