@@ -3,46 +3,13 @@ title: Installation
3author: Jasper Van der Jeugt
3author: Jasper Van der Jeugt
9−Modern web frameworks make it easy to create huge dynamic websites. Why would
10−anyone still care about a static website?
12−- Static websites are fast, because it's simply files served directly from the
14−- Static websites are secure. Nobody has ever found an SQL injection in static
16−- Static websites are easy to deploy. Just copy them to your webhost using
17− (S)FTP/rsync/scp and you are done. They work on all webhosts: no CGI or extra
18− modules needed for the web server.
23−Hakyll is a [Haskell] library meant for creating small-to-medium sized static
24−websites. It is a powerful publishing tool, precisely because of the power of
25−Haskell. By using the awesome [pandoc] library, it is able to create your
26−website from a large variety of input formats.
28−[Haskell]: http://haskell.org/
29−[pandoc]: http://johnmacfarlane.net/pandoc/
33−- easy templating system;
34−- a simple HTTP server for previewing and compiling your website on the go;
35−- powerful syntax highlighting;
36−- modules for common items such as tags and feeds;
39Installation
6Installation
40------------
7------------
42Installation is provided using [cabal], and some packages are available for
9Installation is provided using [cabal], and some packages are available for
43different distributions.
10different distributions.
45− cabal install hakyll
12+ $ cabal install hakyll
47[cabal]: http://www.haskell.org/cabal/
14[cabal]: http://www.haskell.org/cabal/
@@ -50,3 +17,30 @@ Linux distro packages:
51- [Archlinux (AUR)](https://aur.archlinux.org/packages/haskell-hakyll/)
18- [Archlinux (AUR)](https://aur.archlinux.org/packages/haskell-hakyll/)
52- [Debian unstable](http://packages.debian.org/source/sid/haskell-hakyll)
19- [Debian unstable](http://packages.debian.org/source/sid/haskell-hakyll)
21+Building the example site
22+-------------------------
24+Apart from the main Hakyll library, the cabal package also provided you with an
25+executable `hakyll-init` to create an example site. This is an easy way to get
28+ $ hakyll-init my-site
30+If `hakyll-init` is not found, you should make sure `$HOME/.cabal/bin` is in
33+The file `site.hs` holds the configuration of your site, as an executable
34+haskell program. We can compile and run it like this:
40+If you installed `hakyll` with a preview server (this is the default), you can
45+and have a look at your site at
46+[http://localhost:8000/](http://localhost:8000/).