Skip to content

Commit 7861d08

Browse files
authored
Merge pull request pcapriotti#500 from 9999years/readme-use-hsubparser
Use `hsubparser` in the readme examples.
2 parents 8d35175 + ecc3c4b commit 7861d08

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -555,7 +555,7 @@ on each command), and commands can be added with the `command`
555555
modifier. For example,
556556

557557
```haskell
558-
subparser
558+
hsubparser
559559
( command "add" (info addCommand ( progDesc "Add a file to the repository" ))
560560
<> command "commit" (info commitCommand ( progDesc "Record changes to the repository" ))
561561
)
@@ -573,7 +573,7 @@ start :: String -> IO ()
573573
stop :: IO ()
574574

575575
opts :: Parser (IO ())
576-
opts = subparser
576+
opts = hsubparser
577577
( command "start" (info (start <$> argument str idm) idm)
578578
<> command "stop" (info (pure stop) idm) )
579579

@@ -810,11 +810,11 @@ hello :: Parser Sample
810810
hello = Hello <$> many (argument str (metavar "TARGET..."))
811811

812812
sample :: Parser Sample
813-
sample = subparser
813+
sample = hsubparser
814814
( command "hello" (info hello (progDesc "Print greeting"))
815815
<> command "goodbye" (info (pure Goodbye) (progDesc "Say goodbye"))
816816
)
817-
<|> subparser
817+
<|> hsubparser
818818
( command "bonjour" (info hello (progDesc "Print greeting"))
819819
<> command "au-revoir" (info (pure Goodbye) (progDesc "Say goodbye"))
820820
<> commandGroup "French commands:"

0 commit comments

Comments
 (0)