-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add GH token to all code check steps
- Loading branch information
Showing
6 changed files
with
83 additions
and
53 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 |
---|---|---|
@@ -1,52 +1,3 @@ | ||
jsn <- jsonlite::read_json(path) | ||
names(jsn) | ||
testthat::expect_true( | ||
all(c("image","features","customizations") %in% names(jsn)) | ||
) | ||
devtools::check_man() | ||
file.edit("Rprofile") | ||
file.edit(".Rprofile") | ||
BiocManager::repositories() | ||
devtools::check_man() | ||
library(rworkflows) | ||
deparse(BiocManager::repositories()) | ||
cat(deparse(BiocManager::repositories())) | ||
cont4 <- construct_cont(default_tag = "release", | ||
default_registry = "ghcr.io", | ||
run_check_cont = TRUE) | ||
cont4 <- construct_cont(default_tag = "release", | ||
default_registry = NULL, | ||
run_check_cont = TRUE) | ||
is.null(c("a","b")) | ||
library(rworkflows) | ||
cont4 <- construct_cont(default_tag = "release", | ||
default_registry = NULL, | ||
run_check_cont = TRUE) | ||
devoptera::args2vars(construct_cont) | ||
default_registry | ||
default_registry=NULL | ||
default_registry <- check_registry(registry = default_registry) | ||
#### Remove any trailing : (e.g. when default_tag=NULL) #### | ||
cont <- lapply(cont, function(x){ | ||
if(is.null(x)) NULL else trimws(x,whitespace = ":") | ||
}) | ||
#### Run QC #### | ||
cont2 <- lapply(cont,function(co){ | ||
if(is.null(co)){ | ||
return(NULL) | ||
} else if(!grepl("/",co) && | ||
!is.null(default_cont)){ | ||
messager("Only tag name supplied to 'cont'.", | ||
"Assuming default=",shQuote(default_cont),v=verbose) | ||
co <- paste(default_cont,co,sep=":") | ||
} else if(!grepl(":",co) | | ||
!grepl(default_cont,co)) { | ||
return(co) | ||
} | ||
splt <- strsplit(co,":")[[1]] | ||
bioc_version <- rev(splt)[1] | ||
if(isTRUE(versions_explicit)){ | ||
if(grepl(":",co)){ | ||
info <- bioc_r_versions(bioc_version = bioc_version) | ||
return( | ||
paste0(splt[[1]],":RELEASE_",gsub("[.]","_",info$bioc)) | ||
|
@@ -510,3 +461,52 @@ library(rworkflows) | |
?testthat::skip_on_cran() | ||
testthat::skip_if_offline() | ||
readLines("https://hub.docker.com/v2/repositories//bioconductor/bioconductor_docker/tags?page_size=1000") | ||
devtools::check_man() | ||
devtools::install_dev_deps() | ||
devtools::install_dev_deps() | ||
gh::gh_token() | ||
file.edit("~/.Renviron") | ||
credentials::set_github_pat() | ||
gh::gh_token() | ||
devtools::install_dev_deps() | ||
credentials::set_github_pat() | ||
devtools::install_dev_deps() | ||
devtools::build() | ||
devtools::check_man() | ||
version | ||
version | ||
install.packages("devtools") | ||
install.packages("BiocManager") | ||
install.packages("devtools") | ||
devtools::install_dev_deps() | ||
devtools::check_man() | ||
install.packages("roxygen2") | ||
devtools::check_man() | ||
devtools::install_dev_deps() | ||
packageVersion("roxygen2") | ||
version | ||
version | ||
version() | ||
version() | ||
version | ||
rworkflows::use_workflow() | ||
rworkflows::use_workflow(force_new = T) | ||
gh::gh_token() | ||
credentials::set_github_pat() | ||
a1 <- construct_authors() | ||
library() | ||
library(rworkflows) | ||
a1 <- construct_authors() | ||
testthat::expect_equal(as.character(a1), "yourGivenName yourFamilyName <[email protected]> [cre] (yourOrcidId)") | ||
a2 <- construct_authors(authors = "Test 1, Test1") | ||
testthat::expect_equal(as.character(a2), "Test 1, Test1") | ||
testthat::expect_equal(as.character(a1), "yourGivenName yourFamilyName <[email protected]> [cre] (yourOrcidId)") | ||
testthat::expect_true(as.character(a1) %in% | ||
c("yourGivenName yourFamilyName <[email protected]> [cre] (ORCID: yourOrcidId)", | ||
"yourGivenName yourFamilyName <[email protected]> [cre] (yourOrcidId)")) | ||
installed.packages() | ||
names(installed.packages()) | ||
rownames(installed.packages()) | ||
"reticulate" %in% rownames(installed.packages()) | ||
credentials::set_github_pat() | ||
remotes::install_github("r-lib/remotes") |
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
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
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
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 |
---|---|---|
@@ -1,7 +1,10 @@ | ||
test_that("construct_authors works", { | ||
|
||
a1 <- construct_authors() | ||
testthat::expect_equal(as.character(a1), "yourGivenName yourFamilyName <[email protected]> [cre] (yourOrcidId)") | ||
|
||
testthat::expect_true(as.character(a1) %in% | ||
c("yourGivenName yourFamilyName <[email protected]> [cre] (ORCID: yourOrcidId)", | ||
"yourGivenName yourFamilyName <[email protected]> [cre] (yourOrcidId)")) | ||
|
||
a2 <- construct_authors(authors = "Test 1, Test1") | ||
testthat::expect_equal(as.character(a2), "Test 1, Test1") | ||
|
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