Copyright | (c) 2019-2020 Vaclav Svejcar |
---|---|
License | BSD-3-Clause |
Maintainer | vaclav.svejcar@gmail.com |
Stability | experimental |
Portability | POSIX |
Safe Haskell | None |
Language | Haskell2010 |
This module contains custom readers required by the optparse-applicative
library to parse data types such as LicenseType
or FileType
.
Synopsis
Documentation
licenseReader :: ReadM (LicenseType, FileType) Source #
Reader for tuple of LicenseType
and FileType
.
licenseTypeReader :: ReadM LicenseType Source #
Reader for LicenseType
.
parseLicenseAndFileType :: Text -> Maybe (LicenseType, FileType) Source #
Parses LicenseType
and FileType
from the input string,
formatted as licenseType:fileType
.
>>>
parseLicenseAndFileType "bsd3:haskell"
Just (BSD3,Haskell)