-
Notifications
You must be signed in to change notification settings - Fork 42
/
.travis.yml
51 lines (51 loc) · 1.82 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
---
language: nix
env:
global:
- STORE=$HOME/nix-store
- APP_URL=https://ace-thought-249120.appspot.com
cache:
directories:
- $STORE
before_install:
- sudo mkdir -p /etc/nix
- echo "binary-caches = https://cache.nixos.org/ file://$STORE" | sudo tee -a /etc/nix/nix.conf > /dev/null
- echo 'require-sigs = false' | sudo tee -a /etc/nix/nix.conf > /dev/null
before_cache:
- mkdir -p $STORE
- nix copy --to file://$STORE -f shell.nix buildInputs
- nix copy --to file://$STORE -f _apps/data/shell.nix buildInputs
install:
- nix-shell --pure --command "echo 'run nix-shell and exit'"
before_script:
- nix-shell _apps/data/shell.nix --pure --command "echo 'run nix-shell and exit'"
script:
- cd _data/python-pfhub
- nix-shell --command "cd ../../results && make notebooks"
- cd ../..
- nix-shell --command "
pylint _data/*.py &&
flake8 _data/*.py &&
LC_ALL=en_US.UTF-8 black --check _data/*.py &&
LC_ALL=en_US.UTF-8 make simulations &&
find . -name '*.ipynb' -type f -not -path '*/.ipynb_checkpoints/*' -exec touch {} \; &&
make notebooks &&
rm -rf ./_site &&
jekyll build -d ./_site/pfhub && htmlproofer --check-html --only-4xx --allow-hash-href --empty-alt-ignore --checks-to-ignore ImageCheck --file-ignore ./_site/pfhub/node_modules ./_site &&
py.test --ignore=hackathons/hackathon1 --ignore=benchmarks --ignore=_data --nbval --sanitize-with sanitize.cfg --ignore=results &&
coffeelint _includes/coffee/ &&
mocha _site/pfhub/js/test.js
";
- nix-shell _apps/data/shell.nix --pure --command "
cd _apps/data &&
black --check *.py &&
pylint *.py &&
flake8 *.py
";
- nix-shell _apps/box/shell.nix --pure --command "
cd _apps/box &&
py.test &&
black --check *.py &&
pylint *.py &&
flake8 *.py
";