Skip to content

Commit

Permalink
Set LC_ALL first?
Browse files Browse the repository at this point in the history
  • Loading branch information
krlmlr committed Oct 23, 2023
1 parent 4d97d8e commit b5302fb
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion R/local.R
Original file line number Diff line number Diff line change
Expand Up @@ -134,10 +134,12 @@ local_reproducible_output <- function(width = 80,
)

if (isTRUE(capabilities("NLS"))) {
# FIXME: We need a new `locale` argument here, should be consistent
# with the `lang` argument to `local_reproducible_output()`
withr::local_envvar(c(LC_ALL = "en_GB"), .local_envir = .env)
if (!(Sys.getenv("LANG") %in% c("C", "C.UTF-8"))) {
withr::local_language(lang, .local_envir = .env)
}
withr::local_envvar(c(LC_ALL = "en_GB"), .local_envir = .env)
}

withr::local_collate("C", .local_envir = .env)
Expand Down

0 comments on commit b5302fb

Please sign in to comment.