diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-03-31 21:09:19 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-03-31 21:09:19 +0300 |
commit | 676109e1b32682bdbdd94a9ffbd8743784f35521 (patch) | |
tree | 71f0394c68455c1736a14c215992de6aa5fe358c /.gitlab/ci/review.gitlab-ci.yml | |
parent | 5facc34f44ce8736078127a5df174a7b52d922b4 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to '.gitlab/ci/review.gitlab-ci.yml')
-rw-r--r-- | .gitlab/ci/review.gitlab-ci.yml | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/.gitlab/ci/review.gitlab-ci.yml b/.gitlab/ci/review.gitlab-ci.yml index fefadab16e4..1134a76a6b8 100644 --- a/.gitlab/ci/review.gitlab-ci.yml +++ b/.gitlab/ci/review.gitlab-ci.yml @@ -234,7 +234,15 @@ danger-review: - run_timed_command "bundle install --jobs=$(nproc) --path=vendor --retry=3 --quiet --with danger" - run_timed_command "retry yarn install --frozen-lockfile" script: - - run_timed_command "bundle exec danger --fail-on-errors=true --verbose" + - > + if [ -z "$DANGER_GITLAB_API_TOKEN" ]; then + # Force danger to skip CI source GitLab and fallback to "local only git repo". + unset GITLAB_CI + # We need to base SHA to help danger determine the base commit for this shallow clone. + run_timed_command "bundle exec danger dry_run --fail-on-errors=true --verbose --base='$CI_MERGE_REQUEST_DIFF_BASE_SHA'" + else + run_timed_command "bundle exec danger --fail-on-errors=true --verbose" + fi update-danger-review-cache: extends: |