-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5907e58
commit 217ba05
Showing
1 changed file
with
24 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -38,7 +38,7 @@ env: | |
run_covr: 'true' | ||
run_pkgdown: 'true' | ||
has_RUnit: 'false' | ||
cache-version: 'cache-v4' | ||
cache-version: 'cache-v3' | ||
run_docker: 'false' | ||
|
||
jobs: | ||
|
@@ -52,8 +52,7 @@ jobs: | |
fail-fast: false | ||
matrix: | ||
config: | ||
- { os: ubuntu-latest, r: '4.3', bioc: 'devel', cont: "bioconductor/bioconductor_docker:devel", rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest" } | ||
|
||
- { os: ubuntu-latest, r: '4.3', bioc: '3.18', cont: "bioconductor/bioconductor_docker:RELEASE_3_18", rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest" } | ||
env: | ||
R_REMOTES_NO_ERRORS_FROM_WARNINGS: true | ||
RSPM: ${{ matrix.config.rspm }} | ||
|
@@ -71,9 +70,10 @@ jobs: | |
run: | | ||
mkdir /__w/_temp/Library | ||
echo ".libPaths('/__w/_temp/Library')" > ~/.Rprofile | ||
git config --global --add safe.directory /__w/doubletrouble/doubletrouble | ||
- name: Checkout Repository | ||
uses: actions/checkout@v2 | ||
|
||
|
@@ -83,7 +83,6 @@ jobs: | |
uses: r-lib/actions/setup-r@v2 | ||
with: | ||
r-version: ${{ matrix.config.r }} | ||
http-user-agent: ${{ matrix.config.http-user-agent }} | ||
|
||
## pandoc is already included in the Bioconductor docker images | ||
- name: Setup pandoc from r-lib | ||
|
@@ -96,7 +95,7 @@ jobs: | |
saveRDS(remotes::dev_package_deps(dependencies = TRUE), ".github/depends.Rds", version = 2) | ||
shell: Rscript {0} | ||
|
||
- name: Restore R package cache | ||
- name: Cache R packages | ||
if: "!contains(github.event.head_commit.message, '/nocache') && runner.os != 'Linux'" | ||
uses: actions/cache@v2 | ||
with: | ||
|
@@ -136,14 +135,15 @@ jobs: | |
## For installing usethis's dependency gert | ||
brew install libgit2 | ||
## Required for tcltk | ||
brew install xquartz --cask | ||
- name: Install Windows system dependencies | ||
if: runner.os == 'Windows' | ||
run: | | ||
## Edit below if you have any Windows system dependencies | ||
shell: Rscript {0} | ||
## Add code here to install dependencies | ||
# yes | pacman -Sy mingw-w64-x86_64-glpk | ||
# yes | pacman -Sy mingw-w64-x86_64-libxml2 | ||
shell: bash | ||
|
||
- name: Install BiocManager | ||
run: | | ||
|
@@ -165,37 +165,22 @@ jobs: | |
## https://github.com/r-lib/remotes/issues/296 | ||
## Ideally, all dependencies should get installed in the first pass. | ||
## Set the repos source depending on the OS | ||
## Alternatively use https://storage.googleapis.com/bioconductor_docker/packages/ | ||
## though based on https://bit.ly/bioc2021-package-binaries | ||
## the Azure link will be the main one going forward. | ||
gha_repos <- if( | ||
.Platform$OS.type == "unix" && Sys.info()["sysname"] != "Darwin" | ||
) c( | ||
"AnVIL" = "https://bioconductordocker.blob.core.windows.net/packages/3.15/bioc", | ||
BiocManager::repositories() | ||
) else BiocManager::repositories() | ||
## For running the checks | ||
message(paste('****', Sys.time(), 'installing rcmdcheck and BiocCheck ****')) | ||
install.packages(c("rcmdcheck", "BiocCheck"), repos = gha_repos) | ||
## Pass #1 at installing dependencies | ||
## This pass uses AnVIL-powered fast binaries | ||
## details at https://github.com/nturaga/bioc2021-bioconductor-binaries | ||
## The speed gains only apply to the docker builds. | ||
message(paste('****', Sys.time(), 'pass number 1 at installing dependencies: local dependencies ****')) | ||
remotes::install_local(dependencies = TRUE, repos = gha_repos, build_vignettes = FALSE, upgrade = TRUE) | ||
remotes::install_local(dependencies = TRUE, repos = BiocManager::repositories(), build_vignettes = TRUE, upgrade = TRUE, force = TRUE) | ||
continue-on-error: true | ||
shell: Rscript {0} | ||
|
||
- name: Install dependencies pass 2 | ||
run: | | ||
## Pass #2 at installing dependencies | ||
## This pass does not use AnVIL and will thus update any packages | ||
## that have seen been updated in Bioconductor | ||
message(paste('****', Sys.time(), 'pass number 2 at installing dependencies: any remaining dependencies ****')) | ||
remotes::install_local(dependencies = TRUE, repos = BiocManager::repositories(), build_vignettes = TRUE, upgrade = TRUE, force = TRUE) | ||
## For running the checks | ||
message(paste('****', Sys.time(), 'installing rcmdcheck and BiocCheck ****')) | ||
remotes::install_cran("rcmdcheck") | ||
BiocManager::install("BiocCheck") | ||
shell: Rscript {0} | ||
|
||
- name: Install BiocGenerics | ||
|
@@ -227,12 +212,10 @@ jobs: | |
- name: Run CMD check | ||
env: | ||
_R_CHECK_CRAN_INCOMING_: false | ||
DISPLAY: 99.0 | ||
run: | | ||
options(crayon.enabled = TRUE) | ||
rcmdcheck::rcmdcheck( | ||
args = c("--no-manual", "--no-vignettes", "--timings"), | ||
build_args = c("--no-manual", "--keep-empty-dirs", "--no-resave-data"), | ||
args = c("--no-build-vignettes", "--no-manual", "--timings"), | ||
build_args = c("--no-manual", "--no-resave-data"), | ||
error_on = "warning", | ||
check_dir = "check" | ||
) | ||
|
@@ -248,23 +231,14 @@ jobs: | |
run: | | ||
BiocGenerics:::testPackage() | ||
shell: Rscript {0} | ||
|
||
- name: (Temporarily) Install correct version of BiocCheck | ||
run: | | ||
remotes::install_github("Bioconductor/BiocCheck@0a217b4") | ||
shell: Rscript {0} | ||
|
||
|
||
- name: Run BiocCheck | ||
env: | ||
DISPLAY: 99.0 | ||
run: | | ||
BiocCheck::BiocCheck( | ||
package = ".", | ||
dir('check', 'tar.gz$', full.names = TRUE), | ||
`quit-with-status` = TRUE, | ||
`no-check-R-ver` = TRUE, | ||
`no-check-bioc-help` = TRUE, | ||
`no-check-coding-practices` = TRUE, | ||
`no-check-version-num` = TRUE | ||
`no-check-bioc-help` = TRUE | ||
) | ||
shell: Rscript {0} | ||
|
||
|
@@ -278,11 +252,11 @@ jobs: | |
if: github.ref == 'refs/heads/devel' && env.run_pkgdown == 'true' && runner.os == 'Linux' | ||
run: R CMD INSTALL . | ||
|
||
- name: Build and deploy pkgdown site | ||
- name: Deploy package | ||
if: github.ref == 'refs/heads/devel' && env.run_pkgdown == 'true' && runner.os == 'Linux' | ||
run: | | ||
git config --local user.name "$GITHUB_ACTOR" | ||
git config --local user.email "[email protected]" | ||
git config --local user.email "[email protected]" | ||
git config --local user.name "GitHub Actions" | ||
Rscript -e "pkgdown::deploy_to_branch(new_process = FALSE)" | ||
shell: bash {0} | ||
## Note that you need to run pkgdown::deploy_to_branch(new_process = FALSE) | ||
|
@@ -297,12 +271,6 @@ jobs: | |
name: ${{ runner.os }}-biocversion-RELEASE_3_18-r-4.3-results | ||
path: check | ||
|
||
## Note that DOCKER_PASSWORD is really a token for your dockerhub | ||
## account, not your actual dockerhub account password. | ||
## This comes from | ||
## https://seandavi.github.io/BuildABiocWorkshop/articles/HOWTO_BUILD_WORKSHOP.html#6-add-secrets-to-github-repo | ||
## Check https://github.com/docker/build-push-action/tree/releases/v1 | ||
## for more details. | ||
- uses: docker/build-push-action@v1 | ||
if: "!contains(github.event.head_commit.message, '/nodocker') && env.run_docker == 'true' && runner.os == 'Linux' " | ||
with: | ||
|