Skip to content

Commit d277736

Browse files
authored
Merge pull request #7 from mikkel-kaj/fix/windows-compatibility
Fix Unicode crash on Windows
2 parents 39a4c81 + 3fc9d47 commit d277736

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

src/ralphify/cli.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,10 @@
3232
RALPH_TOML_TEMPLATE,
3333
)
3434

35+
if sys.platform == "win32":
36+
sys.stdout.reconfigure(encoding="utf-8")
37+
sys.stderr.reconfigure(encoding="utf-8")
38+
3539
_console = Console(highlight=False)
3640
rprint = _console.print
3741

0 commit comments

Comments
 (0)