Skip to content

Commit

Permalink
Merge pull request #112 from eitsupi/more-error-message
Browse files Browse the repository at this point in the history
more error message support in install2.r
  • Loading branch information
eddelbuettel authored Mar 23, 2023
2 parents 61184b3 + 2e729e8 commit 46dbc22
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
2023-03-23 SHIMA Tatsuya <ts1s1andn@gmail.com>

* inst/examples/install2.r (capture): Update error message pattern
used to detect failure to change in R 4.3.*

2023-03-23 Dirk Eddelbuettel <edd@debian.org>

* inst/examples/install2.r (capture): Small generalisation for
Expand Down
2 changes: 1 addition & 1 deletion inst/examples/install2.r
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ install_packages2 <- function(pkgs, ..., error = FALSE, skipinstalled = FALSE) {
capture <- function(e) {
if (error) {
catch <-
grepl("download of package .* failed", e$message) ||
grepl("(download|installation) of package .* failed", e$message) ||
grepl("(dependenc|package).*(is|are) not available", e$message) ||
grepl("installation of package.*had non-zero exit status", e$message) ||
grepl("installation of .+ package(|s) failed", e$message)
Expand Down

0 comments on commit 46dbc22

Please sign in to comment.