forked from modio/modio-sdk-legacy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
46 lines (42 loc) · 881 Bytes
/
.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
language: c++
os:
- linux
- osx
dist: xenial
sudo: false
script:
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
cmake -D test=on . ;
else
CXX=/usr/bin/g++-5 CC=/usr/bin/gcc-5 cmake -Dtest=on . ;
fi
- make -j2
- make test
- if [[ "$TRAVIS_TAG" ]]; then
cmake -D mode=static . ;
make -j2 ;
fi
- if [ "$TRAVIS_TAG" ]; then
if [ "$TRAVIS_OS_NAME" == "osx" ]; then
zip Macos.zip libmodio.a libmodio.dylib;
else
zip Linux.zip libmodio.a libmodio.so;
fi
fi
deploy:
- provider: releases
api_key: "${token}"
file:
- "Linux.zip"
skip_cleanup: true
on:
tags: true
condition: $TRAVIS_OS_NAME != "osx"
- provider: releases
api_key: "${token}"
file:
- "Macos.zip"
skip_cleanup: true
on:
tags: true
condition: $TRAVIS_OS_NAME == "osx"