improve logging
This commit is contained in:
parent
db03c0dffb
commit
8d927f9eff
2 changed files with 4 additions and 4 deletions
|
|
@ -27,11 +27,11 @@ store_build_metadata <- function(
|
|||
if (nrow(existing_entries) >= 1 && !force) {
|
||||
cli::cli_alert("{.fun store_build_metadata}: Build metadata for {.field {.pkg package_name}} {.field {tag}} already exists.")
|
||||
} else if (nrow(existing_entries) >= 1 && force) {
|
||||
cli::cli_alert_info("{.fun store_build_metadata}: Force overwriting build metadata for {.field {package_name}} {.field {tag}} because {.code force = TRUE} was set.")
|
||||
cli::cli_alert_info("{.fun store_build_metadata}: Force overwriting build metadata for {.pkg {package_name}} {.field {tag}} because {.code force = TRUE} was set.")
|
||||
|
||||
dbExecute(con, sprintf("UPDATE single_builds SET build_timestamp = '%s' WHERE package_name = '%s' and tag = '%s'", format(Sys.time(), "%Y-%m-%d %H:%M:%S"), package_name, tag))
|
||||
} else if (nrow(existing_entries) == 0) {
|
||||
cli::cli_alert("{.fun store_build_metadata}: Storing build metadata for {.field {package_name}} {.field {tag}}.")
|
||||
cli::cli_alert("{.fun store_build_metadata}: Storing build metadata for {.pkg {package_name}} {.field {tag}}.")
|
||||
# Create a data frame with the metadata
|
||||
metadata <- data.frame(
|
||||
package_name = package_name,
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ install_package_system_dependencies <- function(package_name,
|
|||
tag,
|
||||
platform = "redhat-9",
|
||||
local_clone_dir) {
|
||||
cli::cli_alert("{.fun install_package_system_dependencies}: Cloning package {.pkg {package_name[1]}} with tag {.field {tag}}.")
|
||||
cli::cli_alert("{.fun install_package_system_dependencies}: Cloning package {.pkg {package_name[1]}} with tag {.field {tail(tag, 1)}}.")
|
||||
|
||||
t1 <- Sys.time()
|
||||
|
||||
|
|
@ -24,7 +24,7 @@ install_package_system_dependencies <- function(package_name,
|
|||
cli::cli_alert("{.fun install_package_system_dependencies}: Removing {.path {local_clone_dir_single}}.")
|
||||
|
||||
total_build_time <- round(Sys.time() - t1, 2)
|
||||
cli::cli_alert("Execution time for installing dependencies of {.pkg {package_name[[1]]}}: {.strong {total_build_time} {units(difftime(Sys.time(), t1))}}.")
|
||||
cli::cli_alert("Execution time for installing dependencies of package {.pkg {package_name[[1]]}}: {.strong {total_build_time} {units(difftime(Sys.time(), t1))}}.")
|
||||
|
||||
unlink(sprintf("%s", local_clone_dir_single), recursive = TRUE, force = TRUE)
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue