Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CI: Run full workflows on tags #2593

Merged
merged 1 commit into from
Oct 12, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 35 additions & 20 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,10 @@ jobs:
- run:
name: Check whether build should be skipped
command: |
if [[ "$( git log --format='format:%s' -n 1 $CIRCLE_SHA1 | grep -i -E '^docs?(\(\w+\))?:' )" != "" ]]; then
set -x +e
COMMIT_MSG="$(git log --format='format:%s' -n 1 $CIRCLE_SHA1)"
DOCBUILD="$(echo ${COMMIT_MSG} | grep -i -E '^docs?(\(\w+\))?:')"
if [ -z "$CIRCLE_TAG" -a -n "$DOCBUILD" ]; then
echo "Only docs build"
circleci step halt
fi
Expand Down Expand Up @@ -248,11 +251,15 @@ jobs:
name: Check whether build should be skipped
command: |
cd /home/circleci/src/fmriprep
if [[ "$( git log --format='format:%s' -n 1 $CIRCLE_SHA1 | grep -i -E '^docs?(\(\w+\))?:' )" != "" ]]; then
set -x +e
COMMIT_MSG="$(git log --format='format:%s' -n 1 $CIRCLE_SHA1)"
DOCBUILD="$(echo ${COMMIT_MSG} | grep -i -E '^docs?(\(\w+\))?:')"
SKIP_PYTEST="$(echo ${COMMIT_MSG} | grep -i -E '\[skip[ _]?tests\]')"
if [ -z "$CIRCLE_TAG" -a -n "$DOCBUILD" ]; then
echo "Only docs build"
circleci step halt
fi
if [[ "$( git log --format=oneline -n 1 $CIRCLE_SHA1 | grep -i -E '\[skip[ _]?tests\]' )" != "" ]]; then
if [ -z "$CIRCLE_TAG" -a -n "$SKIP_PYTEST" ]; then
echo "Skipping pytest job"
circleci step halt
fi
Expand Down Expand Up @@ -343,18 +350,23 @@ jobs:
- checkout:
path: /home/circleci/src/fmriprep
- run:
name: Check whether build should be skipped
name: Check whether build should be skipped or fast-tracked
command: |
cd /home/circleci/src/fmriprep
if [[ "$( git log --format='format:%s' -n 1 $CIRCLE_SHA1 | grep -i -E '^docs?(\(\w+\))?:' )" != "" ]]; then
set -x +e
COMMIT_MSG="$(git log --format='format:%s' -n 1 $CIRCLE_SHA1)"
DOCBUILD="$(echo ${COMMIT_MSG} | grep -i -E '^docs?(\(\w+\))?:' )"
SKIP_DS005="$(echo ${COMMIT_MSG} | grep -i -E '\[skip[ _]?ds005\]' )"
NO_FASTTRACK="$(echo ${COMMIT_MSG} | grep -i -E '\[no[ _-]?fasttrack\]' )"
if [ -z "$CIRCLE_TAG" -a -n "$DOCBUILD" ]; then
echo "Only docs build"
circleci step halt
fi
if [[ "$( git log --format=oneline -n 1 $CIRCLE_SHA1 | grep -i -E '\[skip[ _]?ds005\]' )" != "" ]]; then
if [ -z "$CIRCLE_TAG" -a -n "$SKIP_DS005" ]; then
echo "Skipping ds000005 build"
circleci step halt
fi
if [[ "$( git log --format=oneline -n 1 $CIRCLE_SHA1 | grep -i -E '\[no[ _-]?fasttrack\]' )" != "" ]]; then
if [[ -n "$NO_FASTTRACK" ]]; then
touch /tmp/.nofasttrack
echo "Anatomical fasttrack reusing sMRIPrep's derivatives will not be used."
fi
Expand Down Expand Up @@ -580,11 +592,15 @@ jobs:
name: Check whether build should be skipped
command: |
cd /home/circleci/src/fmriprep
if [[ "$( git log --format='format:%s' -n 1 $CIRCLE_SHA1 | grep -i -E '^docs?(\(\w+\))?:' )" != "" ]]; then
set -x +e
COMMIT_MSG="$(git log --format='format:%s' -n 1 $CIRCLE_SHA1)"
DOCBUILD="$(echo ${COMMIT_MSG} | grep -i -E '^docs?(\(\w+\))?:')"
SKIP_DS054="$(echo ${COMMIT_MSG} | grep -i -E '\[skip[ _]?ds054\]' )"
if [ -z "$CIRCLE_TAG" -a -n "$DOCBUILD" ]; then
echo "Only docs build"
circleci step halt
fi
if [[ "$( git log --format=oneline -n 1 $CIRCLE_SHA1 | grep -i -E '\[skip[ _]?ds054\]' )" != "" ]]; then
if [ -z "$CIRCLE_TAG" -a -n "$SKIP_DS054" ]; then
echo "Skipping ds000054 build"
circleci step halt
fi
Expand Down Expand Up @@ -743,11 +759,15 @@ jobs:
name: Check whether build should be skipped
command: |
cd /home/circleci/src/fmriprep
if [[ "$( git log --format='format:%s' -n 1 $CIRCLE_SHA1 | grep -i -E '^docs?(\(\w+\))?:' )" != "" ]]; then
set -x +e
COMMIT_MSG="$(git log --format='format:%s' -n 1 $CIRCLE_SHA1)"
DOCBUILD="$(echo ${COMMIT_MSG} | grep -i -E '^docs?(\(\w+\))?:')"
SKIP_DS210="$(echo ${COMMIT_MSG} | grep -i -E '\[skip[ _]?ds054\]' )"
if [ -z "$CIRCLE_TAG" -a -n "$DOCBUILD" ]; then
echo "Only docs build"
circleci step halt
fi
if [[ "$( git log --format=oneline -n 1 $CIRCLE_SHA1 | grep -i -E '\[skip[ _]?ds210\]' )" != "" ]]; then
if [ -z "$CIRCLE_TAG" -a -n "$SKIP_DS210" ]; then
echo "Skipping ds000210 build"
circleci step halt
fi
Expand Down Expand Up @@ -888,14 +908,6 @@ jobs:
fi
- checkout:
path: /home/circleci/src/fmriprep
- run:
name: Check whether build should be skipped
command: |
cd /home/circleci/src/fmriprep
if [[ "$( git log --format='format:%s' -n 1 $CIRCLE_SHA1 | grep -i -E '^docs?(\(\w+\))?:' )" != "" ]]; then
echo "Only docs build"
circleci step halt
fi
- restore_cache:
keys:
- build-v4-{{ .Branch }}-{{ epoch }}
Expand Down Expand Up @@ -946,7 +958,10 @@ jobs:
name: Check whether build should be skipped
command: |
cd /home/circleci/src/fmriprep
if [[ "$( git log --format='format:%s' -n 1 $CIRCLE_SHA1 | grep -i -E '^docs?(\(\w+\))?:' )" != "" ]]; then
set -x +e
COMMIT_MSG="$(git log --format='format:%s' -n 1 $CIRCLE_SHA1)"
DOCBUILD="$(echo ${COMMIT_MSG} | grep -i -E '^docs?(\(\w+\))?:')"
if [ -z "$CIRCLE_TAG" -a -n "$DOCBUILD" ]; then
echo "Only docs build"
circleci step halt
fi
Expand Down