forked from r-dbi/RMariaDB
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
108 lines (95 loc) · 2.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
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
101
102
103
104
105
106
107
108
# R for travis: see documentation at https://docs.travis-ci.com/user/languages/r
# Default configuration for use with tic package
# Usually you shouldn't need to change the first part of the file
# DO NOT CHANGE THE CODE BELOW
before_install:
- if which brew; then brew install mysql && mysql.server start; fi
- R -q -e 'install.packages("remotes"); remotes::install_github("r-lib/remotes")'
- R -q -e 'remotes::install_github("ropenscilabs/tic"); tic::prepare_all_stages(); tic::before_install(); tic::dsl_get()'
install: R -q -e 'tic::install()'
after_install: R -q -e 'tic::after_install()'
before_script:
- R -q -e 'tic::before_script()'
- travis_retry mysql -e "CREATE DATABASE IF NOT EXISTS test; ALTER DATABASE test CHARACTER SET 'utf8'; FLUSH PRIVILEGES;" -uroot
- travis_retry mysql -e "CREATE USER '"${USER}"'@'localhost'; FLUSH PRIVILEGES;" -uroot || true
- travis_retry mysql -e "GRANT ALL PRIVILEGES ON test.* TO '"${USER}"'@'localhost'; FLUSH PRIVILEGES;" -uroot
script: R -q -e 'tic::script()'
after_success: R -q -e 'tic::after_success()'
after_failure: R -q -e 'tic::after_failure()'
after_script: R -q -e 'tic::after_script()'
# DO NOT CHANGE THE CODE ABOVE
# Custom parts:
# Header
language: r
sudo: false
dist: xenial
cache: packages
latex: false
fortran: false
pandoc: false
#stages: test, full
stages:
- name: test
if: branch != docs
- name: docs
if: branch = docs OR branch = master
- name: full
if: branch = master
#env
env:
global:
- _R_CHECK_FORCE_SUGGESTS_=false
- _R_CHECK_SYSTEM_CLOCK_=false
- _R_SHLIB_STRIP_=true
- R_STRIP_SHARED_LIB="/usr/bin/strip -g"
- MAKEFLAGS="-j 2"
- R_CHECK_ARGS="--no-manual --as-cran"
#addons
addons:
apt:
packages:
- libmysqlclient-dev
- libmagick++-dev
- libssh2-1-dev
#jobs
matrix:
include:
- r: devel
env:
- DEV_VERSIONS=true
- r: 3.2
- stage: docs
os: linux
r: release
pandoc: true
env:
- BUILD_PKGDOWN=true
before_deploy: R -q -e 'tic::before_deploy()'
deploy:
provider: script
script: R -q -e 'tic::deploy()'
on:
all_branches: true
after_deploy: R -q -e 'tic::after_deploy()'
- stage: full
os: osx
- os: osx
osx_image: xcode8.3
disable_homebrew: true
env:
- R_CHECK_ARGS="--no-manual --no-tests"
before_script: 'echo no sql server, only testing build'
- os: linux
r: 3.4
- os: linux
r: 3.3
fast_finish: true
#notifications
notifications:
email:
on_success: change
on_failure: change
# Custom parts:
#services
services:
- MySQL