Skip to content

Commit

Permalink
try once more
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinushey committed Dec 20, 2024
1 parent 6d444b6 commit a3ae93b
Showing 1 changed file with 1 addition and 15 deletions.
16 changes: 1 addition & 15 deletions R/files.R
Original file line number Diff line number Diff line change
Expand Up @@ -579,21 +579,7 @@ renv_file_broken_unix <- function(paths) {
# unfortunately, as far as I know, there isn't a more reliable
# way of detecting broken junction points on Windows using vanilla R
renv_file_broken_win32 <- function(paths) {

owd <- getwd()
on.exit(setwd(owd), add = TRUE)

broken <- rep.int(FALSE, length(paths))
for (i in seq_along(paths)) {
if (dir.exists(paths[[i]])) {
broken[[i]] <- tryCatch(
!nzchar(setwd(paths[[i]])),
error = function(cnd) TRUE
)
}
}
broken

!map_lgl(paths, Sys.setFileTime, Sys.time())
}

renv_file_size <- function(path) {
Expand Down

0 comments on commit a3ae93b

Please sign in to comment.