forked from DOI-USGS/streamMetabolizer
-
Notifications
You must be signed in to change notification settings - Fork 1
/
.travis.yml
69 lines (57 loc) · 1.68 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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
# Defines the options for building the project on linux with Travis-CI
# For more configuration options, see the wiki:
# https://github.com/craigcitro/r-travis/wiki/Porting-to-native-R-support-in-Travis
language: r
sudo: required
warnings_are_errors: true
matrix:
include:
- os: linux
dist: trusty
r: release
r_binary_packages:
- devtools
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-7
env:
- MATRIX_EVAL="CC=gcc-7 && CXX=g++-7"
before_install:
- eval "${MATRIX_EVAL}"
- mkdir -p ~/.R/
- echo "CXX14 = g++-7 -fPIC" >> ~/.R/Makevars
- echo "CXX14FLAGS = -mtune=native -march=native -Wno-unused-variable -Wno-unused-function -Wno-unused-local-typedefs -Wno-ignored-attributes -Wno-deprecated-declarations -Wno-attributes -O3" >> ~/.R/Makevars
env:
global:
- R_BUILD_ARGS="--no-build-vignettes --no-manual"
- R_CHECK_ARGS="--no-build-vignettes --no-manual --as-cran"
- NOT_CRAN="true"
- _R_CHECK_FORCE_SUGGESTS_=false
repos:
CRAN: https://cran.rstudio.com
GRAN: https://owi.usgs.gov/R
before_script:
- Rscript -e "install.packages('knitr')"
- Rscript -e "install.packages('rmarkdown')"
r_packages:
- deSolve
- rstan
r_github_packages:
- jimhester/covr
- GLEON/LakeMetabolizer
script:
- |
R CMD build ${R_BUILD_ARGS} .
PKG_FILE_NAME=$(ls -1t *.tar.gz | head -n 1)
travis_wait 40 R CMD check ${R_CHECK_ARGS} "${PKG_FILE_NAME}"
after_success:
- if [[ "${R_CODECOV}" ]]; then travis_wait 20 R -e 'covr::coveralls()'; fi
after_failure:
- ./travis-tool.sh dump_logs
notifications:
email:
on_success: change
on_failure: change