fix grepl pattern in update packages
This commit is contained in:
parent
b2f7999666
commit
c23011b811
1 changed files with 131 additions and 131 deletions
|
|
@ -65,7 +65,7 @@ archive_package <- function(
|
|||
# get most recent version from CRAN
|
||||
last_version <- available.packages("https://cloud.r-project.org/src/contrib")[.x, "Version"]
|
||||
# check if last version is available in repo
|
||||
if (any(grepl(last_version, all_versions))) {
|
||||
if (any(grepl(sprintf("^%s_%s.tar.gz", package_name, last_version), all_versions))) {
|
||||
index <- which(grepl(sprintf("_%s.tar.gz", last_version), all_versions, fixed = TRUE))
|
||||
old_versions <- all_versions[-index]
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Reference in a new issue