forked from FAIRDataPipeline/rDataPipeline
-
Notifications
You must be signed in to change notification settings - Fork 0
65 lines (56 loc) · 2.22 KB
/
Copy pathSCRCdataAPI.yaml
File metadata and controls
65 lines (56 loc) · 2.22 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
name: SCRCdataAPI # Name of the project (this is what is displayed on the badge)
on: [push] # Event on which GitHub will run the CI
jobs:
build:
name: ${{ matrix.os }} Build
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false # fail-fast means should it fail the other job if the one fails
matrix:
os: ['ubuntu-latest', 'macos-latest']
steps:
- uses: actions/checkout@v2 # Check out the code
- uses: r-lib/actions/setup-r@master # Nice fast way to setup R
- name: Install System Requirements (macOS)
run : |
rm /usr/local/bin/gfortran
brew install gdal openssl hdf5 udunits proj
if: matrix.os == 'macos-latest'
- name: Install System Requirements (Ubuntu)
run : sudo apt-get install libcurl4-openssl-dev libhdf5-dev libudunits2-dev libproj-dev libgdal-dev -y
if: matrix.os == 'ubuntu-latest'
- name: Install required R libraries
env:
DEBIAN_FRONTEND: noninteractive # Stop R asking where to download from
run: |
install.packages("assertthat")
install.packages("configr")
install.packages("dplyr")
install.packages("hdf5r")
install.packages("httr")
install.packages("jsonlite")
install.packages("nomisr")
install.packages("readxl")
install.packages("reshape2")
install.packages("rgdal")
install.packages("sf")
install.packages("SQPARQL")
install.packages("stats")
install.packages("testthat")
install.packages("tibble")
install.packages("tidyr")
install.packages("units")
install.packages("utils")
shell: Rscript {0}
- name: Install SCRC Data SCRCdataAPI
env:
DEBIAN_FRONTEND: noninteractive # Might not be needed a second time, but still
run: |
install.packages("devtools")
library(devtools)
install_github("ScottishCovidResponse/SCRCdataAPI")
shell: Rscript {0}
- name: Test API import
run: |
library(SCRCdataAPI)
shell: Rscript {0}