mirror of
https://github.com/ilyakooo0/vty.git
synced 2024-11-29 16:54:42 +03:00
follow up to #89 - ensure string are the same case
This commit is contained in:
parent
0b4fa6410b
commit
4aa1873485
@ -92,9 +92,9 @@ reserveTerminal variant outFd = liftIO $ do
|
|||||||
utf8Active :: IO Bool
|
utf8Active :: IO Bool
|
||||||
utf8Active = do
|
utf8Active = do
|
||||||
let vars = ["LC_ALL", "LANG", "LC_CTYPE"]
|
let vars = ["LC_ALL", "LANG", "LC_CTYPE"]
|
||||||
results <- catMaybes <$> mapM getEnv vars
|
results <- map (toLower <$>) . catMaybes <$> mapM getEnv vars
|
||||||
let matches = filter ("UTF8" `isInfixOf`) results <>
|
let matches = filter ("utf8" `isInfixOf`) results <>
|
||||||
filter ("UTF-8" `isInfixOf`) results
|
filter ("utf-8" `isInfixOf`) results
|
||||||
return $ not $ null matches
|
return $ not $ null matches
|
||||||
|
|
||||||
-- | Enable bracketed paste mode:
|
-- | Enable bracketed paste mode:
|
||||||
|
Loading…
Reference in New Issue
Block a user