-
Notifications
You must be signed in to change notification settings - Fork 4
/
sf.travis.yml
94 lines (82 loc) · 2.56 KB
/
sf.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
language: r
r:
- release
- oldrel # breaks on sf_0.7-2 not available
- devel
deploy.skip_cleanup: true
sudo: required
dist: trusty
cache:
- packages
- ccache
latex: false
r_github_packages:
- r-spatial/stars
- r-spatial/s2
# - r-dbi/DBI
# - r-dbi/RPostgres
# - r-lib/covr
# - r-spatial/lwgeom
addons:
# postgresql: "10"
apt:
sources:
- sourceline: 'ppa:opencpu/jq'
- sourceline: 'ppa:ubuntugis/ubuntugis-unstable'
- sourceline: 'deb http://apt.postgresql.org/pub/repos/apt/ trusty-pgdg main'
key_url: 'https://www.postgresql.org/media/keys/ACCC4CF8.asc'
packages:
- devscripts # checkbashisms
- libprotobuf-dev
- protobuf-compiler
- libv8-3.14-dev
- libjq-dev
- libudunits2-dev
- libproj-dev
- libgeos-dev
- libspatialite-dev
- libgdal-dev
- libjson-c-dev
- libnetcdf-dev
- netcdf-bin
# - postgresql-server-dev-9.6
# - postgis
before_install:
# install postgis from source, to avoid dependency conflict with GDAL >= 2.0:
#- wget http://download.osgeo.org/postgis/source/postgis-3.0.1.tar.gz
#- (mv postgis* /tmp; cd /tmp; tar xzf postgis-3.0.1.tar.gz)
#- (cd /tmp/postgis-3.0.1 ; ./configure; make; sudo make install)
# activate liblwgeom by:
## - sudo ldconfig
# create postgis databases:
#- sudo service postgresql restart
#- createdb postgis
#- psql -d postgis -c "CREATE EXTENSION postgis;"
#- psql -d postgis -c "GRANT CREATE ON DATABASE postgis TO travis"
#- psql -d postgis -c "GRANT ALL PRIVILEGES ON ALL TABLES IN SCHEMA public TO travis"
#- createdb empty
#- psql -d empty -c "CREATE EXTENSION postgis;"
- R -e 'install.packages("rgdal", repos="http://R-Forge.R-project.org")'
- R -q -e 'install.packages("remotes"); remotes::install_github("ropenscilabs/tic"); tic::prepare_all_stages()'
after_success:
#- dropdb postgis
#- dropdb empty
#- createdb postgis
#- psql -d postgis -c "CREATE EXTENSION postgis;"
#- psql -d postgis -c "GRANT CREATE ON DATABASE postgis TO travis"
#- psql -d postgis -c "GRANT ALL PRIVILEGES ON ALL TABLES IN SCHEMA public TO travis"
#- createdb empty
#- psql -d empty -c "CREATE EXTENSION postgis;"
- R -q -e 'covr::codecov(quiet = FALSE)'
install: R -q -e 'tic::install()'
script: R -q -e 'tic::script()'
before_deploy: R -q -e 'tic::before_deploy()'
deploy:
provider: script
script: R -q -e 'tic::deploy()'
on:
branch: master
condition:
- $TRAVIS_PULL_REQUEST = false
- $TRAVIS_EVENT_TYPE != cron
- $TRAVIS_R_VERSION_STRING = release