Haskell web site
HTML CSS Haskell JavaScript
Switch branches/tags
Nothing to show
Clone or download
Pull request Compare This branch is 438 commits ahead, 1 commit behind yogsototh:master.
Latest commit 843e93c Jun 5, 2018
Permalink
Failed to load latest commit information.
config
design
scripts
src
static
themes/purple/fonts
.arcconfig
.dir-locals.el
.ghci
.gitignore
LICENSE
README.md
Setup.hs
hl.cabal
hl.org
stack.yaml

README.md

hl

Haskell.org web site.

Editing pages

If you're just here to contribute a content change, read this section.

All pages that are produced by markdown are here. To contribute changes simply fork this repo and open a pull request. It will be merged and redeployed in short order.

If you want to edit a page which has some custom code in it, you'll want to see the next sections for building and running instructions. Maybe also take a look at architecture.

If you want to include Haskell code samples in markdown, use:

``` haskell
main = putStrLn "Hello, World!"
```

If you want to include Haskell code samples in Haskell code pages, use:

haskellPre "main = print 123"
haskellCode "peyton `simon` jones"

Pre for <pre> block, code for <code> span snippet.

Building

Clone the repo:

$ git clone git@github.com:haskell-infra/hl.git

Set up sandbox:

$ cabal sandbox init

Install dependencies and build:

$ cabal install --only-dependencies
$ cabal build

Done!

CSS Assets

In static/source, run:

$ npm install
$ bower install

to install all the source libraries locally (you need nodejs installed). Then:

$ gulp css

to create a new CSS file (automatically creates a minified version as well).

Running

(Note: from within a development env where you run out of the dist folder, you want to ensure that development in src/HL/Development.hs is set to "True").

It runs at: http://localhost:1990/

Manually running the binary:

$ dist/build/hl/hl

Running from inside GHCi:

> :l DevelMain
> DevelMain.update

Run this every time you want to update the web handler in-place, as in this demo.

If you use Emacs, you can just bind it to a key:

(define-key html-mode-map [f12] 'haskell-process-reload-devel-main)

Just hit f12 to recompile and restart.

Architecture

It uses Yesod and an MVC organization.

Templates are written in Lucid. There is presently no database.

Style

We generally use this style for this project. You don't have to use this style, we can reformat patches as they come in.