-
Notifications
You must be signed in to change notification settings - Fork 0
90 lines (89 loc) · 3.46 KB
/
main.yaml
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
name: CI
on:
push:
branches:
- 'main'
- 'scratch/**'
tags:
- '[0-9]+.[0-9]+.[0-9]+'
- '[0-9]+.[0-9]+.[0-9]+.[0-9]+'
pull_request:
jobs:
check:
runs-on: ${{ matrix.config.os }}
name: ${{ matrix.config.os }} (${{ matrix.config.r }})
strategy:
fail-fast: false
matrix:
# Reason for source compatibility kludges:
# * pbkrtest 0.5.2 requires R 4.1.
# * Matrix v1.7-0 requires R 4.4.
config:
- os: ubuntu-20.04
r: 3.6.3
pbkrtest_pkg: 'url::https://mpn.metworx.com/snapshots/stable/2023-12-05/src/contrib/pbkrtest_0.5.1.tar.gz'
matrix_pkg: 'url::https://mpn.metworx.com/snapshots/stable/2024-09-23/src/contrib/Matrix_1.6-5.tar.gz'
# The latest versions of several dependencies require
# newer R versions.
rspm: 'https://packagemanager.posit.co/cran/__linux__/focal/2023-11-15'
- os: ubuntu-20.04
r: 4.0.5
pbkrtest_pkg: 'url::https://mpn.metworx.com/snapshots/stable/2023-12-05/src/contrib/pbkrtest_0.5.1.tar.gz'
matrix_pkg: 'url::https://mpn.metworx.com/snapshots/stable/2024-09-23/src/contrib/Matrix_1.6-5.tar.gz'
# The latest versions of several dependencies require
# newer R versions.
rspm: 'https://packagemanager.posit.co/cran/__linux__/focal/2024-07-22'
- os: ubuntu-20.04
r: 4.1.3
pbkrtest_pkg: 'url::https://mpn.metworx.com/snapshots/stable/2023-12-05/src/contrib/pbkrtest_0.5.1.tar.gz'
matrix_pkg: 'url::https://mpn.metworx.com/snapshots/stable/2024-09-23/src/contrib/Matrix_1.6-5.tar.gz'
# The latest versions of several dependencies require
# newer R versions.
rspm: 'https://packagemanager.posit.co/cran/__linux__/focal/2024-07-22'
- os: ubuntu-20.04
r: 4.2.3
matrix_pkg: 'url::https://mpn.metworx.com/snapshots/stable/2024-09-23/src/contrib/Matrix_1.6-5.tar.gz'
- os: ubuntu-20.04
r: 4.3.1
matrix_pkg: 'url::https://mpn.metworx.com/snapshots/stable/2024-09-23/src/contrib/Matrix_1.6-5.tar.gz'
- os: ubuntu-latest
r: release
env:
R_KEEP_PKG_SOURCE: yes
steps:
- uses: actions/checkout@v4
- uses: r-lib/actions/setup-r@v2
with:
r-version: ${{ matrix.config.r }}
use-public-rspm: true
env:
RSPM: ${{ matrix.config.rspm }}
- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: |
any::rcmdcheck
${{ matrix.config.pbkrtest_pkg }}
${{ matrix.config.matrix_pkg }}
upgrade: ${{ matrix.config.r == 'release' && 'TRUE' || 'FALSE' }}
- uses: r-lib/actions/check-r-package@v2
release:
if: github.ref_type == 'tag'
name: Upload release
needs: check
runs-on: ubuntu-latest
permissions:
id-token: write
contents: read
steps:
- uses: actions/checkout@v4
- uses: metrumresearchgroup/actions/mpn-latest@v1
- uses: r-lib/actions/setup-r@v2
with:
r-version: release
use-public-rspm: true
# For pkgpub.
extra-repositories: 'https://mpn.metworx.com/snapshots/stable/${{ env.MPN_LATEST }}'
- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::pkgpub
- uses: metrumresearchgroup/actions/publish-r-release@v1