forked from devsim/devsim
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.travis.yml
More file actions
74 lines (61 loc) · 1.9 KB
/
.travis.yml
File metadata and controls
74 lines (61 loc) · 1.9 KB
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
language: cpp
matrix:
include:
- os: osx
env: COMPILER=gcc
osx_image: xcode10.1
# - os: linux
# sudo: required
# dist: trusty
# services: docker
# - os: osx
# env: COMPILER=clang
addons:
homebrew:
packages:
- gcc@9
update: false
#https://github.com/travis-ci/travis-ci/issues/6893
if: tag IS present
# prevent duplicate builds on tagged versions on master
# development to be done on other branches
#branches:
# except:
# - master
before_install:
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then
docker run -it -d --name centos7 centos:7 &&
(cd .. && tar czf devsim.tgz devsim && docker cp devsim.tgz centos7:/root/) &&
docker exec centos7 bash -c "cd /root && tar xzf devsim.tgz";
fi
#install:
script:
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then
docker exec centos7 bash -c "cd /root/devsim && source scripts/install_miniconda_linux.sh && bash scripts/build_centos_7.sh devsim_linux_${TRAVIS_TAG}";
fi
- if [ "$TRAVIS_OS_NAME" == "osx" ]; then
source ./scripts/install_miniconda_macos.sh;
if [ "$COMPILER" == "gcc" ]; then
./scripts/build_macos.sh $COMPILER "${TRAVIS_TAG}";
elif [ "$COMPILER" == "clang" ]; then
./scripts/build_macos.sh $COMPILER "clang_${TRAVIS_TAG}";
fi
fi
before_deploy:
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then
(cd dist && docker cp centos7:/root/devsim/dist/devsim_linux_${TRAVIS_TAG}.tgz .);
fi
deploy:
provider: releases
api_key:
secure: F2Cxh/mYSqsmCTsggWqD2frhUW5x94D2bl61zj2JHYyTUSU0KXyzFp8aQAaGzfyaoBlc9G5JlveozrwPFnJQK9Yh+IW5wj8yiDXA0s2hv/vhlmVQZ/PqOZBXDeHmmptnfZtRuMAFrZD/zm9BUwNi6/2czRFxn5JYKjb45SavV4Q=
file_glob: true
file: "dist/devsim*.tgz"
skip_cleanup: true
prerelease: false
draft: true
# fix issue with multiple deployments https://github.com/travis-ci/travis-ci/issues/6132
tag_name: $TRAVIS_TAG
on:
repo: devsim/devsim
tags: true