Skip to content

Commit f7e51f8

Browse files
iconv to prevent gibberish in GHA logs
1 parent 0a3723f commit f7e51f8

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

.github/workflows/R-CMD-check-occasional.yaml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,18 @@ jobs:
100100
with:
101101
r-version: ${{ matrix.r }}
102102

103+
- name: Override R for locale-specific check
104+
if: matrix.os == 'ubuntu-latest' && !contains(matrix.locale, 'utf8')
105+
run: |
106+
sudo mkdir -p /override
107+
sudo tee /override/R << 'EOF'
108+
#!/bin/bash
109+
set -o pipefail
110+
exec $(which R) "$@" 2>&1 | iconv -c -t UTF-8
111+
EOF
112+
sudo chmod +x /override/R
113+
echo "PATH=/override:$PATH" >> $GITHUB_ENV
114+
103115
- name: Set script permissions
104116
run: chmod +x configure cleanup 2>/dev/null || true # Silence some GHA Annotations
105117
shell: bash

0 commit comments

Comments
 (0)