-
Notifications
You must be signed in to change notification settings - Fork 24
77 lines (63 loc) · 1.75 KB
/
r.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
on: [push, pull_request,repository_dispatch]
defaults:
run:
shell: bash
jobs:
R:
name: R
runs-on: ubuntu-20.04
env:
GEN: ninja
DUCKDB_PATH: ../duckdb/
steps:
- uses: r-lib/actions/setup-r@v2
with:
r-version: 'devel'
- uses: actions/setup-python@v2
with:
python-version: '3.9'
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Update DuckDB submodule
run: |
git config --global --add safe.directory '*'
make pull
- name: Install
env:
GITHUB_PAT: ${{ github.token }}
shell: bash
run: |
sudo apt-get update -y -qq && sudo apt-get install -y -qq ninja-build libcurl4-openssl-dev
mkdir -p $HOME/.R
(cd scripts && R -f dependencies.R)
- uses: actions/checkout@v3
with:
path: ${{ env.DUCKDB_SRC }}
- uses: actions/checkout@v3
with:
repository: ${{ env.DUCKDB_R_REPO }}
path: ${{ env.DUCKDB_R_SRC }}
# needed so we can run git commit in vendor.sh
- name: setup github and create parallel builds
shell: bash
run: |
git config --global user.email "[email protected]"
git config --global user.name "mr. duck"
mkdir -p ~/.R
echo 'MAKEFLAGS = -j2' >> ~/.R/Makevars
# error is from git_dev_version() but does not affect this workflow
- name: update duckdb-r src code with PR code
shell: bash
working-directory: ${{ env.DUCKDB_R_SRC }}
run: (cd duckdb-r && ./vendor.sh)
- name: Build Extension
run: |
make release
- name: Build DuckDB (R)
run: |
cd duckdb-r
R CMD INSTALL .
- name: Test R
run: |
(cd test/r && R -f test_substrait.R)