Skip to content

Commit

Permalink
clean verbosity options code for update fns #92
Browse files Browse the repository at this point in the history
  • Loading branch information
mpadge committed Jan 17, 2025
1 parent ec5ae97 commit 9c53c93
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 13 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: pkgmatch
Title: Find R Packages Matching Either Descriptions or Other R Packages
Version: 0.4.3.006
Version: 0.4.3.007
Authors@R: c(
person("Mark", "Padgham", , "[email protected]", role = c("aut", "cre"),
comment = c(ORCID = "0000-0003-2172-5265")),
Expand Down
7 changes: 2 additions & 5 deletions R/data-update-cran.R
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,8 @@ pkgmatch_update_cran <- function () {
cli::cli_inform ("Downloading and analysing {npkgs} packages.")

pt0 <- proc.time ()
op <- getOption ("rlib_message_verbosity", "notset")
op_is_quiet <- op == "quiet"
if (op == "notset") {
op <- NULL
}
op_is_quiet <- opt_is_quiet ()
op <- getOption ("rlib_message_verbosity")
options ("rlib_message_verbosity" = "quiet")

res <- lapply (seq_along (new_cran_pkgs), function (p) {
Expand Down
7 changes: 2 additions & 5 deletions R/data-update-ropensci.R
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,8 @@ pkgmatch_update_ropensci <- function () {
}

pt0 <- proc.time ()
op <- getOption ("rlib_message_verbosity", "notset")
op_is_quiet <- op == "quiet"
if (op == "notset") {
op <- NULL
}
op_is_quiet <- opt_is_quiet ()
op <- getOption ("rlib_message_verbosity")
options ("rlib_message_verbosity" = "quiet")

res <- lapply (seq_len (nrow (reg_updated)), function (i) {
Expand Down
2 changes: 1 addition & 1 deletion R/utils.R
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
opt_is_quiet <- function () {
options ("rlib_message_verbosity") == "quiet"
options ("rlib_message_verbosity", "notset") == "quiet"
}

#' Estimate whether input text string is code or English prose text.
Expand Down
2 changes: 1 addition & 1 deletion codemeta.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"codeRepository": "https://github.com/ropensci-review-tools/pkgmatch",
"issueTracker": "https://github.com/ropensci-review-tools/pkgmatch/issues",
"license": "https://spdx.org/licenses/MIT",
"version": "0.4.3.006",
"version": "0.4.3.007",
"programmingLanguage": {
"@type": "ComputerLanguage",
"name": "R",
Expand Down

0 comments on commit 9c53c93

Please sign in to comment.