1
1
mirror of https://github.com/anoma/juvix.git synced 2024-12-15 01:52:11 +03:00
juvix/app/Commands/Dev/Doc.hs
Jonathan Cubides 01a44e436d
Refactor (#1420)
* Big refactor in process

* remove unnecessary functions from the prelude

* remove comments
2022-08-03 13:20:40 +02:00

31 lines
612 B
Haskell

module Commands.Dev.Doc where
import Juvix.Prelude hiding (Doc)
import Options.Applicative
data DocOptions = DocOptions
{ _docOutputDir :: FilePath,
_docOpen :: Bool
}
makeLenses ''DocOptions
parseDoc :: Parser DocOptions
parseDoc = do
_docOutputDir <-
option
str
( long "output-dir"
<> metavar "DIR"
<> value "doc"
<> showDefault
<> help "html output directory"
<> action "directory"
)
_docOpen <-
switch
( long "open"
<> help "open the documentation after generating it"
)
pure DocOptions {..}