We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Parsing a bool variable, not only does "true" not work as a value, but the error message is not helpful in finding out that I should specify "True":
"true"
"True"
Parse failure: could not parse variable "TEST_BOOL" into type [Char]
The text was updated successfully, but these errors were encountered:
yea, it just uses the Read instance for Bool.
Read
Bool
instance Var Bool where toVar = show; fromVar = readMaybe
Sorry, something went wrong.
You can make your own though.
newtype Thing = Thing Bool instance FromEnv Thing where fromEnv _ = fmap Thing $ (True <$ (env "true" <|> env "True")) <|> (False <$ (env "false" <|> env "False"))
No branches or pull requests
Parsing a bool variable, not only does
"true"
not work as a value, but the error message is not helpful in finding out that I should specify"True"
:The text was updated successfully, but these errors were encountered: