Commit graph

6 commits

Author SHA1 Message Date
Joey Hess
7c5007279c
Windows: Fix escaping output to terminal when using old versions of MinTTY 2024-03-26 13:09:21 -04:00
Joey Hess
db95de6f2b
clean up windows build warnings about unused imports 2024-03-26 13:06:52 -04:00
Joey Hess
2efceba789
fix windows build 2023-04-12 19:33:19 -04:00
Joey Hess
c5bcb55a8b
add ScopedTypeVariables 2023-04-12 19:19:22 -04:00
Joey Hess
2fdb6ca879
remove unused imports 2023-04-12 16:48:18 -04:00
Joey Hess
a576fc3b12
fix mojibake reversion in display of utf8
When displaying a ByteString like "💕", safeOutput operates on
individual bytes like "\240\159\146\149" and isControl '\146' = True,
so it got truncated to just "\240".

So, only treat the low control characters, and DEL, as control
characters.

Also split Utility.Terminal out of Utility.SafeOutput. The latter needs
win32, but Utility.SafeOutput is used by Control.Exception, which is
used by Setup.

Sponsored-by: Nicholas Golder-Manning on Patreon
2023-04-12 13:53:30 -04:00