Commit e0205d4b authored by Lena Hersemann's avatar Lena Hersemann

added seconds to file timestamp; cosmetics

parent f3c81acf
......@@ -68,7 +68,7 @@ if(!file.exists(r_script)){
# check previous script versions
script_name <- str_replace(basename(r_script), ".R", "")
current_script <- paste0(".", script_name, "_", format(Sys.time(), "%Y%m%d_%H%M.R"))
current_script <- paste0(".", script_name, "_", format(Sys.time(), "%Y%m%d_%H%M%S.R"))
all_files <- file.info(list.files(".", pattern = paste0("\\.", script_name), all.files = T))
all_files <- all_files[str_detect(rownames(all_files), ".R$"),]
......@@ -84,7 +84,7 @@ diffFile(recent_script, r_script, mode = "sidebyside")
if(row_diff > 0) {
print("ATTENTION: the script has been changed")
cat("Would you like to overwrite the existing data? [Yes/No]")
cat("Would you like to overwrite the existing data? [Yes/No] ")
inp <- readLines(file("stdin"), n = 1L)
if (!inp == "Yes" & !inp %in% "No") {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment