Skip to content

Commit

Permalink
BLD: Add platform-specific skips
Browse files Browse the repository at this point in the history
Add the ability to manually skip appveyor or travis using the commit message

The syntax is:

[skip appveyor]
[skip travis]
  • Loading branch information
bashtage committed Sep 21, 2018
1 parent e1822d4 commit e576aa8
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,10 @@ notifications:
on_success: always

before_install:
# Skip if commit message contains [skip travis] or [travis skip]
- COMMIT_MESSAGE=$(git show -s $TRAVIS_COMMIT_RANGE | awk 'BEGIN{count=0}{if ($1=="Author:") count++; if (count==1) print $0}')
- if [[ $TRAVIS_PULL_REQUEST == false ]]; then COMMIT_MESSAGE=${TRAVIS_COMMIT_MESSAGE}; fi
- if echo "$COMMIT_MESSAGE" | grep -E '\[(skip travis|travis skip)\]'; then exit 0 ; fi
# Show information about CPU running job to understand BLAS issues
- sudo lshw -class processor
# Fix for headless TravisCI
Expand Down
4 changes: 4 additions & 0 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ platform:
- x64

build_script:
# Search for [appveyor skip] or [skip appveyor] and exit if found in full commit message
- ps: $commit=$env:APPVEYOR_REPO_COMMIT_MESSAGE + $env:APPVEYOR_REPO_COMMIT_MESSAGE_EXTENDED
- ps: $skip_appveyor=$commit.Contains("[skip appveyor]") -Or $commit.Contains("[appveyor skip]")
- ps: If ($skip_appveyor) { echo "[skip appveyor]"; Exit-AppVeyorBuild }
# Show information about CPU running job to understand BLAS issues
- wmic cpu get caption, name, numberofcores
- SET MKL_NUM_THREADS=1
Expand Down

0 comments on commit e576aa8

Please sign in to comment.