diff options
author | Thijs Schreijer <thijs@thijsschreijer.nl> | 2024-06-19 22:05:33 +0200 |
---|---|---|
committer | Thijs Schreijer <thijs@thijsschreijer.nl> | 2024-06-19 22:05:33 +0200 |
commit | e0871d7be63dd428d4a2b9a3db4e033894165cef (patch) | |
tree | 9a844f267ec9ec99ba745680453b683dd73a6f5b /examples/compat.lua | |
parent | 8996a5022fa82e5d5335f71580d0cd6b6d323c9b (diff) | |
download | luasystem-e0871d7be63dd428d4a2b9a3db4e033894165cef.tar.gz luasystem-e0871d7be63dd428d4a2b9a3db4e033894165cef.tar.bz2 luasystem-e0871d7be63dd428d4a2b9a3db4e033894165cef.zip |
add system.CODEPAGE_UTF8 for 65001 codepage
Diffstat (limited to 'examples/compat.lua')
-rw-r--r-- | examples/compat.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/compat.lua b/examples/compat.lua index a59d964..c712105 100644 --- a/examples/compat.lua +++ b/examples/compat.lua | |||
@@ -12,7 +12,7 @@ if sys.windows then | |||
12 | os.getenv = sys.getenv -- luacheck: ignore | 12 | os.getenv = sys.getenv -- luacheck: ignore |
13 | 13 | ||
14 | -- Set console output to UTF-8 encoding. | 14 | -- Set console output to UTF-8 encoding. |
15 | sys.setconsoleoutputcp(65001) | 15 | sys.setconsoleoutputcp(sys.CODEPAGE_UTF8) |
16 | 16 | ||
17 | -- Set up the terminal to handle ANSI escape sequences on Windows. | 17 | -- Set up the terminal to handle ANSI escape sequences on Windows. |
18 | if sys.isatty(io.stdout) then | 18 | if sys.isatty(io.stdout) then |