mirror of
https://github.com/xmonad/xmonad-contrib.git
synced 2025-08-01 04:31:52 -07:00
X.D.Developing: Update Haddock introduction
* The Haddock documentation is a very good resource for the general markup syntax. * Since we are very biased in favour of stack, document how to build Haddock docks with it.
This commit is contained in:
@@ -273,8 +273,9 @@ xmonad-contrib.cabal file. There should be no warnings.
|
|||||||
* Any pure function added to the core must have QuickCheck properties
|
* Any pure function added to the core must have QuickCheck properties
|
||||||
precisely defining its behaviour. Tests for everything else are encouraged.
|
precisely defining its behaviour. Tests for everything else are encouraged.
|
||||||
|
|
||||||
For examples of Haddock documentation syntax, have a look at other
|
For examples of Haddock documentation syntax, have a look at
|
||||||
extensions. Important points are:
|
<https://haskell-haddock.readthedocs.io/en/latest/markup.html its documentation>
|
||||||
|
or other extensions. Important points are:
|
||||||
|
|
||||||
* Every exported function (or even better, every function) should have
|
* Every exported function (or even better, every function) should have
|
||||||
a Haddock comment explaining what it does, and providing examples.
|
a Haddock comment explaining what it does, and providing examples.
|
||||||
@@ -291,6 +292,13 @@ extensions. Important points are:
|
|||||||
|
|
||||||
To generate and view the Haddock documentation for your extension, run
|
To generate and view the Haddock documentation for your extension, run
|
||||||
|
|
||||||
|
> stack haddock --no-haddock-deps
|
||||||
|
|
||||||
|
If the builds succeeds, at the end stack should tell you where the
|
||||||
|
generated @index.html@ is located.
|
||||||
|
|
||||||
|
Alternatively, you can run
|
||||||
|
|
||||||
> runhaskell Setup haddock
|
> runhaskell Setup haddock
|
||||||
|
|
||||||
and then point your browser to @\/path\/to\/XMonadContrib\/dist\/doc\/html\/xmonad-contrib\/index.html@.
|
and then point your browser to @\/path\/to\/XMonadContrib\/dist\/doc\/html\/xmonad-contrib\/index.html@.
|
||||||
|
Reference in New Issue
Block a user