forked from rdiaz02/OncoSimul
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
100 lines (59 loc) · 3.15 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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# Sample .travis.yml for R projects +
# https://github.com/travis-ci/travis-ci/issues/5775
## This does not seeem fully, given that bioc uses r-release from mid
# april to mid october: https://www.bioconductor.org/developers/how-to/useDevel/
## So this is what it seems I need: from mid-April to mid-Octorer use:
## x1 and x11:
## Otherwise use x2 and x22
## ##### x1
## language: r
## r:
## - bioc-release
##### x2
language: r
r:
- bioc-devel
warnings_are_errors: true
sudo: required
cache: packages
r_github_packages:
- r-lib/covr
## ####### x11
## ## try to use bioc devel with an R release
## install:
## - Rscript -e 'install.packages("BiocManager"); BiocManager::install(version="devel", ask = FALSE); install.packages(c("devtools","testthat","roxygen2","Oncotree","rmarkdown","bookdown", "withr", "ggplot2", "ggrepel", "pander", "knitr"));BiocManager::install("BiocStyle", ask = FALSE);devtools::install_deps("OncoSimulR");devtools::install_github("r-lib/covr")'
####### x22
install:
- Rscript -e 'install.packages("BiocManager"); BiocManager::install(version="devel", ask = FALSE); install.packages(c("devtools","testthat","roxygen2","Oncotree","rmarkdown","bookdown", "withr", "covr", "ggplot2", "ggrepel", "pander", "knitr")); BiocManager::install("BiocStyle", ask = FALSE); devtools::install_deps("OncoSimulR")'
# withr failing because of a broken dependency on "later". FIXME: return to using github' jimhester for withr and covr later.
# install:
# - Rscript -e 'install.packages(c("devtools","knitr","testthat","roxygen2","Oncotree","rmarkdown","bookdown"));source("http://bioconductor.org/biocLite.R");options(repos=biocinstallRepos());biocLite(c("BiocStyle"));devtools::install_deps("OncoSimulR");devtools::install_github("jimhester/withr");devtools::install_github("jimhester/covr")'
before_script:
- R CMD build --keep-empty-dirs OncoSimulR
script:
- R CMD check OncoSimulR_*.tar.gz
after_success:
- Rscript -e 'library(covr); options(covr.flags = c(CPPFLAGS = "-O3 -g --coverage", CXX1XFLAGS = "-O3 -g --coverage", CXXFLAGS = "-O3 -g --coverage", CFLAGS = "-O3 -g --coverage", LDFLAGS = "--coverage")); covr::codecov(path = "./OncoSimulR")'
notifications:
email:
on_success: change
on_failure: change
## Remember to fix the file paths as:
## R/::OncoSimulR/R
## src/::OncoSimulR/src
## so that codecov info is shown.
## Remember that OS X could be used instead of Linux.
## But it is instead of, not in addition to. See:
## "Linux or OS X builds" in https://github.com/craigcitro/r-travis
## Do I still need this?
# https://github.com/travis-ci/travis-ci/issues/6587
# Set CXX1X for R-devel, as R-devel does not detect CXX1X support for gcc 4.6.3,
# this was causing hunspell installation to fail
## before_install:
## - if [[ "$TRAVIS_R_VERSION_STRING" = 'bioc-devel' ]]; then mkdir ~/.R && echo 'CXX1X=g++ -std=c++0x -g -O2 -fPIC' > ~/.R/Makevars; fi
## If we get
## Error in get0(oNam, envir = ns) :
## lazy-load database '/home/travis/R/Library/pkgbuild/R/pkgbuild.rdb' is corrupt
## try deleting the cache in travis:
## settings -> cache -> delete
## https://github.com/marinebon/p2p/issues/5#issuecomment-447877732