-
Notifications
You must be signed in to change notification settings - Fork 531
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Richard Feldman
committed
Feb 1, 2018
1 parent
d60d1ef
commit 45a2f7e
Showing
1 changed file
with
38 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
sudo: false | ||
|
||
cache: | ||
directories: | ||
- tests/elm-stuff/build-artifacts | ||
- sysconfcpus | ||
|
||
before_install: | ||
- echo -e "Host github.com\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config | ||
- | # epic build time improvement - see https://github.com/elm-lang/elm-compiler/issues/1473#issuecomment-245704142 | ||
if [ ! -d sysconfcpus/bin ]; | ||
then | ||
git clone https://github.com/obmarg/libsysconfcpus.git; | ||
cd libsysconfcpus; | ||
./configure --prefix=$TRAVIS_BUILD_DIR/sysconfcpus; | ||
make && make install; | ||
cd ..; | ||
fi | ||
install: | ||
- nvm install $TARGET_NODE_VERSION | ||
- nvm use $TARGET_NODE_VERSION | ||
- node --version | ||
- npm --version | ||
- npm install -g elm@0.18.0 elm-test elm-format@exp | ||
- mv $(npm config get prefix)/bin/elm-make $(npm config get prefix)/bin/elm-make-old | ||
- printf '%s\n\n' '#!/bin/bash' 'echo "Running elm-make with sysconfcpus -n 2"' '$TRAVIS_BUILD_DIR/sysconfcpus/bin/sysconfcpus -n 2 elm-make-old "$@"' > $(npm config get prefix)/bin/elm-make | ||
- chmod +x $(npm config get prefix)/bin/elm-make | ||
- travis_retry elm-package install --yes | ||
- cd tests | ||
- npm install | ||
- travis_retry elm-package install --yes | ||
- cd .. | ||
|
||
script: | ||
- elm-format --validate src tests | ||
- cd .. |