Skip to content

Commit

Permalink
For optparse-applicative-0.18: use pretty instead of text
Browse files Browse the repository at this point in the history
Fixes #215
  • Loading branch information
andreasabel committed Jun 9, 2023
1 parent fe1c64a commit 105ddd3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions yaml/exe/json2yaml.hs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 15,7 @@ import Options.Applicative
, long, metavar, short, strArgument, strOption, value
)
import Options.Applicative.Help.Pretty
( vcat, text )
( vcat, pretty )

import System.Exit ( die )

Expand Down Expand Up @@ -43,11 43,11 @@ options =
<> footerDoc fdoc

where
hdoc = Just $ vcat $ map text
hdoc = Just $ vcat $ map pretty
[ versionText self
, "Convert JSON to YAML."
]
fdoc = Just $ text $ concat
fdoc = Just $ pretty $ concat
[ "The old call pattern '"
, self
, " IN OUT' is also accepted, but deprecated."
Expand Down
4 changes: 2 additions & 2 deletions yaml/exe/yaml2json.hs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 17,7 @@ import Options.Applicative
, long, metavar, short, strArgument, strOption, value
)
import Options.Applicative.Help.Pretty
( vcat, text )
( vcat, pretty )

import Common
( versionText, versionOption, numericVersionOption, dashToNothing )
Expand All @@ -43,7 43,7 @@ options =
(headerDoc hdoc)

where
hdoc = Just $ vcat $ map text
hdoc = Just $ vcat $ map pretty
[ versionText self
, "Convert YAML to JSON."
]
Expand Down

0 comments on commit 105ddd3

Please sign in to comment.