1
0
mirror of https://github.com/msberends/AMR.git synced 2025-07-10 14:21:48 +02:00

(v2.1.1.9205) Fix python wrapper

This commit is contained in:
2025-03-15 16:14:29 +01:00
parent afb97ad38f
commit ede1cdfd99
5 changed files with 31 additions and 25 deletions

View File

@ -636,9 +636,15 @@ styler::style_pkg(include_roxygen_examples = FALSE,
exclude_dirs = list.dirs(full.names = FALSE, recursive = FALSE)[!list.dirs(full.names = FALSE, recursive = FALSE) %in% c("R", "tests")])
# Document pkg ------------------------------------------------------------
files_changed <- function(paths = c("R/", "data/")) {
tryCatch({
changed_files <- system("git diff --name-only", intern = TRUE)
any(changed_files %like% "^(R|data)/")
}, error = function(e) TRUE)
}
if (interactive()) {
message("Skipping document in interactive mode")
} else {
} else if (files_changed()) {
usethis::ui_info("Documenting package")
suppressMessages(devtools::document(quiet = TRUE))
}