-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/


-- | hpack's dhalling
--   
--   Work with hpack's top-level <a>fields</a> in a Dhall record with the
--   following executables;
--   
--   <ul>
--   <li>with <tt>dhall-hpack-cabal</tt> write the <tt>.cabal</tt> for a
--   <tt>.dhall</tt> package description.</li>
--   <li>with <tt>dhall-hpack-dhall</tt> show the package description
--   expression, with imports resolved.</li>
--   <li>with <tt>dhall-hpack-json</tt> show the package description as
--   JSON.</li>
--   <li>with <tt>dhall-hpack-yaml</tt> show the package description as
--   YAML.</li>
--   </ul>
@package hpack-dhall
@version 0.5.2

module Hpack.Fields

-- | A default field ordering comparison.
cmp :: (Ord a, IsString a) => a -> a -> Ordering


-- | The functions in this module make it possible to configure an
--   <a>hpack</a> package description with <a>Dhall</a> instead of
--   <a>YAML</a>. When doing so, note that all functions resolve imports
--   relative to the location of the given <tt>.dhall</tt> input file.
module Hpack.Dhall

-- | A file decoder for hpack. This should evaluate to a single record with
--   hpack's top-level <a>fields</a>.
fileToJson :: FilePath -> IO (Either String ([String], Value))

-- | Pretty prints JSON for the package description.
showJson :: Maybe (Text -> Text -> Ordering) -> FilePath -> IO String

-- | Pretty prints YAML for the package description.
showYaml :: Maybe (Text -> Text -> Ordering) -> FilePath -> IO String

-- | Pretty prints the package description Dhall expression, resolving
--   imports relative to the location of the <tt>.dhall</tt> file.
showDhall :: FilePath -> IO String

-- | The default package file name is <tt>package.dhall</tt>.
packageConfig :: FilePath
