homepage: https://github.com/cdornan/optparse-enum#readme
changelog-type: markdown
hash: f3d0f604d339ede9aac6e68e9549f9fade81cb9096650fd354575b7b2f3e83e9
test-bench-deps: {}
maintainer: chris@chrisdornan.com
synopsis: An enum-text based toolkit for optparse-applicative
changelog: |
  # Changelog for optparse-enum

  ## Unreleased changes
basic-deps:
  fmt: ! '>=0.6'
  base: ! '>=4.8 && <10'
  text: ! '>=1.2.2.2'
  enum-text: ! '>=0.5.1.0'
  optparse-applicative: ! '>=0.12'
all-versions:
- 1.0.0.0
author: Chris Dornan
latest: 1.0.0.0
description-type: markdown
description: |
  # optparse-enum

  An `enum-text` based toolkit for `optparse-applicative`.

  A simple but complete example:

  ```haskell
  {-# LANGUAGE DeriveAnyClass    #-}
  {-# LANGUAGE DerivingVia       #-}
  {-# LANGUAGE OverloadedStrings #-}

  import Fmt
  import Text.Enum.Optparse
  import Paths_optparse_enum

  data Choice
    = C_version
    | C_hello
    deriving (Bounded,Enum,EnumText,Eq,Ord,Show)
    deriving (Buildable,TextParsable) via UsingEnumText Choice

  parserDetails ::   ParserDetails
  parserDetails =
    ParserDetails
      { _pd_desc   = "optparse-enum example program"
      , _pd_header = "A simple optparse-enum illustrative program"
      , _pd_footer = "See the optparse-enum page on Hackage for details"
      }

  main :: IO ()
  main = do
    choice <- parseIO parserDetails enumSwitchesP
    case choice of
      C_version -> print    version
      C_hello   -> putStrLn "Hello!"
  ```
license-name: BSD-3-Clause

Update from Hackage at 2019-07-21T17:24:15Z
Update from Hackage at 2019-07-21T17:24:15Z
