-
Notifications
You must be signed in to change notification settings - Fork 10
/
.travis.yml
43 lines (43 loc) · 1.51 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
addons:
apt:
packages:
- libgmp-dev
before_install:
- sh script/install-stack.sh
cache:
directories:
- "${HOME}/.local/bin"
- "${HOME}/.stack"
- ".stack-work"
env:
global:
- CASHER_TIME_OUT=1000
- BUILD="elmi-to-json-${TRAVIS_TAG}-${TRAVIS_OS_NAME}.tar.gz"
language: c
matrix:
include:
- os: linux
dist: xenial
- os: osx
sudo: false
script:
- stack setup
- stack test
- |
if [ "$TRAVIS_OS_NAME" = linux ]; then
echo "Compiling static binary"
stack build --ghc-options "-O2 -fPIC" --flag="elmi-to-json:static"
else
echo "Compiling dynamic binary"
stack build --ghc-options -O2
fi
- tar zcvf "${BUILD}" -C "$(stack path --local-install-root)/bin" elmi-to-json
deploy:
provider: releases
api_key:
- secure: sPkmWPCZwVUyXxCLnV641UXVDTJArFu5KwH0Ni9BJzRW8Wdjo95YEa73WgN3/XDzOmtTyCvYSK8UNXRunRfsoaJbWp6BeNO4YHOxkJvufyd1gcsRoQTywwA0cEJVtvZgKAFGh5RwkI2GOfJFMVSx6nHWVYgfZy8l8jK9pXD+dFnpxe6DB+hPUksChei16BIwV+ijGdvzz/APh0uBX+Z9LIM08tAMF3B+YaPix8wFObkr6VXECCCnS2AElLQ+UxDGG3t0iz2xWeihZUs2cEX5vOv6DCDAvrwR6kT7dMaP0m18088Wpnv+76Am5bokZlDexOYVh7G5QvWbaVh1KyTRfI9ew43ENIB3ZG6LpkFaEPh/gvlU91UxH+E23QORbL7asCyP2jlgOfzvldVnvqDf+ZnyTGP/zh7+xcxTgKqErFH8WKz0j8C3hd0TF5QuKH+Ioe0oXCxecdmoxH4px/1M9+U6NzVLh1vcH7MkMk3DXF2teL7ZHCjUna0eUJdgtg5CuocG5jfIZIjFeJuysg8xSrAzQ7bQTLzsp1QD5PClKM3JTWAR/0GCuR05HK/CJXZ48rPmqVJVfpniM32I8BMCU26jmRwI/ht7xvQtOHSCFNBOe1k8TX2cYUpOTu33Ip816LnwuQ3rUPEyReYLG6XW83Jkp4tBtowiLS+e8urY+lQ=
file: "${BUILD}"
skip_cleanup: true
on:
repo: stoeffel/elmi-to-json
tags: true