forked from lightgbm-org/LightGBM
-
Notifications
You must be signed in to change notification settings - Fork 0
78 lines (76 loc) · 2.22 KB
/
main.yml
File metadata and controls
78 lines (76 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
66
67
68
69
70
71
72
73
74
75
76
77
78
name: GitHub Actions
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
test:
name: ${{ matrix.task }} (${{ matrix.os }}, ${{ matrix.compiler }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
task: r-package
compiler: gcc
r_version: 3.6
- os: ubuntu-latest
task: r-package
compiler: gcc
r_version: 4.0
- os: ubuntu-latest
task: r-package
compiler: clang
r_version: 3.6
- os: ubuntu-latest
task: r-package
compiler: clang
r_version: 4.0
- os: macOS-latest
task: r-package
compiler: gcc
r_version: 3.6
- os: macOS-latest
task: r-package
compiler: gcc
r_version: 4.0
- os: macOS-latest
task: r-package
compiler: clang
r_version: 3.6
- os: macOS-latest
task: r-package
compiler: clang
r_version: 4.0
steps:
- name: Checkout repository
uses: actions/checkout@v1
with:
fetch-depth: 5
submodules: true
- name: Setup and run tests on Linux and macOS
if: matrix.os != 'windows-latest'
shell: bash
run: |
export TASK="${{ matrix.task }}"
export COMPILER="${{ matrix.compiler }}"
export GITHUB_ACTIONS="true"
if [[ "${{ matrix.os }}" == "macOS-latest" ]]; then
export OS_NAME="macos"
export R_MAC_VERSION=3.6.3
elif [[ "${{ matrix.os }}" == "ubuntu-latest" ]]; then
export OS_NAME="linux"
export R_LINUX_VERSION=3.6.3-1bionic;
fi
export BUILD_DIRECTORY="$GITHUB_WORKSPACE"
export CONDA_ENV="test-env"
export CONDA="$HOME/miniconda"
export PATH="$CONDA/bin:${HOME}/.local/bin:$PATH"
export LGB_VER=$(head -n 1 VERSION.txt)
export R_VERSION="${{ matrix.r_version }}"
$GITHUB_WORKSPACE/.ci/setup.sh
$GITHUB_WORKSPACE/.ci/test.sh