-
Notifications
You must be signed in to change notification settings - Fork 14
/
.travis.yml
55 lines (47 loc) · 1.05 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
52
53
54
55
sudo: false
language: generic
services:
- postgresql
addons:
apt:
packages:
- libgmp-dev
- postgresql-client
- postgresql-server-dev-all
postgresql: "9.6"
before_install:
- cd frontend
- npm install
- cd ..
install:
# stack
- mkdir -p ~/.local/bin
- travis_retry curl -L https://github.com/commercialhaskell/stack/releases/download/v1.7.1/stack-1.7.1-linux-x86_64.tar.gz | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack'
- export PATH=~/.local/bin:$PATH
- stack --no-terminal --version
- stack install happy
- stack install alex
# backend
- stack install yesod-bin
# test suite
- stack install hspec-discover
# database
- echo "CREATE USER moot WITH PASSWORD 'moot';" | psql postgres
- createdb -O moot moot
# build frontend
before_script:
- cd frontend
- npm run-script build
- cd ..
script:
- stack setup
- stack update
- stack build --fast -j1
- stack test --fast
cache:
timeout: 6000
directories:
- $HOME/.cabal
- $HOME/.ghc
- $HOME/.stack
- .stack-work/