@@ -108,7 +108,14 @@ jobs:
108
108
- /home/runner/work/_temp/Library:/usr/local/lib/R/host-site-library
109
109
110
110
steps :
111
- # # Most of these steps are the same as the ones in
111
+ - name : Install Git
112
+ run : |
113
+ sudo add-apt-repository ppa:git-core/ppa -y
114
+ sudo apt-get update
115
+ sudo apt-get install git -y
116
+ shell : bash {0}
117
+
118
+ # # Related to https://github.com/actions/checkout/issues/238## Most of these steps are the same as the ones in
112
119
# # https://github.com/r-lib/actions/blob/master/examples/check-standard.yaml
113
120
# # If they update their steps, we will also need to update ours.
114
121
- uses : actions/checkout@v2
@@ -117,24 +124,52 @@ jobs:
117
124
run : |
118
125
install.packages('remotes')
119
126
saveRDS(remotes::dev_package_deps(dependencies = TRUE), ".github/depends.Rds", version = 2)
127
+ message(paste('****', Sys.time(), 'installing BiocManager ****'))
128
+ remotes::install_cran("BiocManager")
120
129
shell : Rscript {0}
121
130
131
+ # # Find the corresponding R version based on the Bioconductor version
132
+ # # to use for the macOS and Windows checks by the next GHA job
133
+ - id : findrversion
134
+ run : |
135
+ ## Find what branch we are working on
136
+ if echo "$GITHUB_REF" | grep -q "master"; then
137
+ biocversion="devel"
138
+ elif echo "$GITHUB_REF" | grep -q "RELEASE_"; then
139
+ biocversion="release"
140
+ fi
141
+
142
+ ## Define the R and Bioconductor version numbers
143
+ biocversionnum=$(Rscript -e "info <- BiocManager:::.version_map_get_online('https://bioconductor.org/config.yaml'); res <- subset(info, BiocStatus == '${biocversion}')[, 'Bioc']; cat(as.character(res))")
144
+ rversion=$(Rscript -e "info <- BiocManager:::.version_map_get_online('https://bioconductor.org/config.yaml'); res <- subset(info, BiocStatus == '${biocversion}')[, 'R']; cat(as.character(res))")
145
+
146
+ ## Print the results
147
+ echo $biocversion
148
+ echo $biocversionnum
149
+ echo $rversion
150
+
151
+ ## Save the info for the next job
152
+ echo "::set-output name=rversion::${rversion}"
153
+ echo "::set-output name=biocversionnum::${biocversionnum}"
154
+ shell :
155
+ bash {0}
156
+
122
157
- name : Cache R packages
123
158
if : " !contains(github.event.head_commit.message, '/nocache')"
124
159
uses : actions/cache@v1
125
160
with :
126
161
path : /home/runner/work/_temp/Library
127
- key : ${{ env.cache-version }}-${{ runner.os }}-r- biocdocker-bioc -${{ needs.define-docker-info.outputs.biocversion }}-${{ hashFiles('.github/depends.Rds') }}
128
- restore-keys : ${{ env.cache-version }}-${{ runner.os }}-r- biocdocker-bioc -${{ needs.define-docker-info.outputs.biocversion }}-
129
-
130
- - name : Install system dependencies
131
- if : runner.os == 'Linux'
132
- env :
133
- RHUB_PLATFORM : linux-x86_64-ubuntu-gcc
134
- run : |
135
- Rscript -e "remotes::install_github('r-hub/sysreqs')"
136
- sysreqs=$(Rscript -e "cat(sysreqs::sysreq_commands('DESCRIPTION'))")
137
- sudo -s eval "$sysreqs"
162
+ key : ${{ env.cache-version }}-${{ runner.os }}-biocdocker-biocbranch -${{ needs.define-docker-info.outputs.biocversion }}-r-${{ steps.findrversion.outputs.rversion }}-bioc-${{ steps.findrversion.outputs.biocversionnum }}-${{ hashFiles('.github/depends.Rds') }}
163
+ restore-keys : ${{ env.cache-version }}-${{ runner.os }}-biocdocker-biocbranch -${{ needs.define-docker-info.outputs.biocversion }}-r-${{ steps.findrversion.outputs.rversion }}-bioc-${{ steps.findrversion.outputs.biocversionnum }}-
164
+
165
+ # - name: Install system dependencies
166
+ # if: runner.os == 'Linux'
167
+ # env:
168
+ # RHUB_PLATFORM: linux-x86_64-ubuntu-gcc
169
+ # run: |
170
+ # Rscript -e "remotes::install_github('r-hub/sysreqs')"
171
+ # sysreqs=$(Rscript -e "cat(sysreqs::sysreq_commands('DESCRIPTION'))")
172
+ # sudo -s eval "$sysreqs"
138
173
139
174
- name : Install dependencies
140
175
run : |
@@ -144,8 +179,6 @@ jobs:
144
179
## https://stat.ethz.ch/pipermail/bioc-devel/2020-April/016675.html
145
180
## https://github.com/r-lib/remotes/issues/296
146
181
## Ideally, all dependencies should get installed in the first pass.
147
- message(paste('****', Sys.time(), 'installing BiocManager ****'))
148
- remotes::install_cran("BiocManager")
149
182
150
183
## Pass #1 at installing dependencies
151
184
message(paste('****', Sys.time(), 'pass number 1 at installing dependencies: local dependencies ****'))
@@ -176,7 +209,7 @@ jobs:
176
209
177
210
- name : Check
178
211
env :
179
- _R_CHECK_CRAN_INCOMING_REMOTE_ : false
212
+ _R_CHECK_CRAN_INCOMING_ : false
180
213
run : |
181
214
rcmdcheck::rcmdcheck(
182
215
args = c("--no-build-vignettes", "--no-manual", "--timings"),
@@ -236,37 +269,11 @@ jobs:
236
269
# # branch (erasing anything you haven't version controlled!) and
237
270
# # makes the git history recognizable by pkgdown.
238
271
239
- # # Find the corresponding R version based on the Bioconductor version
240
- # # to use for the macOS and Windows checks by the next GHA job
241
- - id : findrversion
242
- run : |
243
- ## Find what branch we are working on
244
- if echo "$GITHUB_REF" | grep -q "master"; then
245
- biocversion="devel"
246
- elif echo "$GITHUB_REF" | grep -q "RELEASE_"; then
247
- biocversion="release"
248
- fi
249
-
250
- ## Define the R and Bioconductor version numbers
251
- biocversionnum=$(Rscript -e "info <- BiocManager:::.version_map_get_online('https://bioconductor.org/config.yaml'); res <- subset(info, BiocStatus == '${biocversion}')[, 'Bioc']; cat(as.character(res))")
252
- rversion=$(Rscript -e "info <- BiocManager:::.version_map_get_online('https://bioconductor.org/config.yaml'); res <- subset(info, BiocStatus == '${biocversion}')[, 'R']; cat(as.character(res))")
253
-
254
- ## Print the results
255
- echo $biocversion
256
- echo $biocversionnum
257
- echo $rversion
258
-
259
- ## Save the info for the next job
260
- echo "::set-output name=rversion::${rversion}"
261
- echo "::set-output name=biocversionnum::${biocversionnum}"
262
- shell :
263
- bash {0}
264
-
265
272
- name : Upload check results
266
273
if : failure()
267
274
uses : actions/upload-artifact@master
268
275
with :
269
- name : ${{ runner.os }}-r- biocdocker-bioc -${{ needs.define-docker-info.outputs.biocversion }}-results
276
+ name : ${{ runner.os }}-biocdocker-biocbranch -${{ needs.define-docker-info.outputs.biocversion }}-r-${{ steps.findrversion.outputs.rversion }}-bioc-${{ steps.findrversion.outputs.biocversionnum }}-results
270
277
path : check
271
278
272
279
# # Run R CMD check on both macOS and Windows. You can also run the
@@ -288,12 +295,13 @@ jobs:
288
295
# # Comment/Un-comment in case you also want to run other versions
289
296
- {os: windows-latest}
290
297
- {os: macOS-latest}
291
- # - {os: ubuntu-16.04, rspm: "https://demo.rstudiopm .com/all /__linux__/xenial/latest"}
298
+ # - {os: ubuntu-16.04, rspm: "https://packagemanager.rstudio .com/cran /__linux__/xenial/latest"}
292
299
293
300
env :
294
301
R_REMOTES_NO_ERRORS_FROM_WARNINGS : true
295
302
RSPM : ${{ matrix.config.rspm }}
296
303
BIOCVERSIONNUM : ${{ needs.R-CMD-check-bioc.outputs.biocversionnum }}
304
+ GITHUB_PAT : ${{ secrets.GITHUB_TOKEN }}
297
305
298
306
steps :
299
307
- uses : actions/checkout@v2
@@ -317,8 +325,8 @@ jobs:
317
325
uses : actions/cache@v1
318
326
with :
319
327
path : ${{ env.R_LIBS_USER }}
320
- key : ${{ env.cache-version }}-${{ runner.os }}-r-${{ needs.R-CMD-check-bioc.outputs.rversion }}-bioc-${{ needs.define-docker-info.outputs.biocversion }}-${{ hashFiles('.github/depends.Rds') }}
321
- restore-keys : ${{ env.cache-version }}-${{ runner.os }}-r-${{ needs.R-CMD-check-bioc.outputs.rversion }}-bioc-${{ needs.define-docker-info.outputs.biocversion }}-
328
+ key : ${{ env.cache-version }}-${{ runner.os }}-biocbranch-${{ needs.define-docker-info.outputs.biocversion }}- r-${{ needs.R-CMD-check-bioc.outputs.rversion }}-bioc-${{ needs.define-docker-info.outputs.biocversion }}-${{ hashFiles('.github/depends.Rds') }}
329
+ restore-keys : ${{ env.cache-version }}-${{ runner.os }}-biocbranch-${{ needs.define-docker-info.outputs.biocversion }}- r-${{ needs.R-CMD-check-bioc.outputs.rversion }}-bioc-${{ needs.define-docker-info.outputs.biocversion }}-
322
330
323
331
- name : Install Linux system dependencies
324
332
if : runner.os == 'Linux'
@@ -350,6 +358,7 @@ jobs:
350
358
351
359
- name : Install BiocManager
352
360
run : |
361
+ message(paste('****', Sys.time(), 'installing BiocManager ****'))
353
362
remotes::install_cran("BiocManager")
354
363
shell : Rscript {0}
355
364
@@ -366,8 +375,6 @@ jobs:
366
375
## https://stat.ethz.ch/pipermail/bioc-devel/2020-April/016675.html
367
376
## https://github.com/r-lib/remotes/issues/296
368
377
## Ideally, all dependencies should get installed in the first pass.
369
- message(paste('****', Sys.time(), 'installing BiocManager ****'))
370
- remotes::install_cran("BiocManager")
371
378
372
379
## Pass #1 at installing dependencies
373
380
message(paste('****', Sys.time(), 'pass number 1 at installing dependencies: local dependencies ****'))
@@ -388,7 +395,7 @@ jobs:
388
395
389
396
- name : Check
390
397
env :
391
- _R_CHECK_CRAN_INCOMING_REMOTE_ : false
398
+ _R_CHECK_CRAN_INCOMING_ : false
392
399
run : |
393
400
rcmdcheck::rcmdcheck(
394
401
args = c("--no-build-vignettes", "--no-manual", "--timings"),
@@ -418,5 +425,5 @@ jobs:
418
425
if : failure()
419
426
uses : actions/upload-artifact@master
420
427
with :
421
- name : ${{ runner.os }}-r-${{ needs.R-CMD-check-bioc.outputs.rversion }}-bioc-${{ needs.define-docker-info.outputs.biocversion }}-results
428
+ name : ${{ runner.os }}-biocbranch-${{ needs.define-docker-info.outputs.biocversion }}- r-${{ needs.R-CMD-check-bioc.outputs.rversion }}-bioc-${{ needs.define-docker-info.outputs.biocversion }}-results
422
429
path : check
0 commit comments