Skip to content

Commit 191147a

Browse files
committed
GHA summary: more UTF-8 tries on Windows
1 parent 86479d8 commit 191147a

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

R/gha-summary.R

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,14 @@ create_gha_summary <- function(results) {
88
return()
99
}
1010

11-
out <- file(out, open = "wba", encoding = "UTF-8")
11+
out <- file(out, open = "a+b", encoding = "unknown")
1212
on.exit(close(out), add = TRUE)
1313

14-
p <- function(...) cat(..., file = out, append = TRUE)
14+
p <- function(...) {
15+
s <- paste0(...)
16+
Encoding(s) <- "unknown"
17+
cat(s, file = out, append = TRUE)
18+
}
1519
fmt_time <- function(x) sprintf("%.3fs", x)
1620

1721
results <- lapply(results, gha_summarize_test)

0 commit comments

Comments
 (0)