# Haskell/Notes for contributors

Along with a range of print books, there are a number of Haskell tutorials scattered around the web. None of these can provide a one-stop-shop for the student of Haskell. The print books mostly describe Haskell 98, but since then many of the "extensions" introduced by GHC have since become de facto standards. In addition, the theory and practice of monads has expanded greatly and arrows are starting to become used in mainstream libraries. Hence, the neophyte Haskeller is faced with a collection of disorganised resources, including textbooks, academic papers written by and for experts, isolated tutorials and explanations on Wiki pages, and, of course, willing helpers on mailing lists, IRC channels, and forums.
Making the most of all the resources can be a frustrating and difficult experience. Ideally, this Wikibook will continue to evolve and grow along with the language. We want a definitive reference where Haskell programmers can easily find the next thing that they must learn and then learn to understand it fully and clearly. To this end, contributors should observe the following:

## What you can do

Anyone who knows some Haskell should be able to contribute here. If you are...
* New to Haskell: Please read through some of the first modules in the book. These will be crucial to you starting to understand the language. If they're not clear enough, they need to be changed. If you can't understand them, or find they don't provide a wide enough knowledge base, add a complaint on one of the talk pages (best to do it to the talk page of the contents page).
* Still getting used to Haskell: You're in the perfect position to 'refactor' the beginners' modules in the Wikibook! You know best what's helpful to newcomers and what's just downright confusing. Be brave, delete large chunks of text if they're simply rubbish.
* Growing up with Haskell: There are plenty of tasks for you. The Wikibook needs better coverage of the Hierarchical modules (don't overlap with the Haddock docs too much, though) as well as new exercises (and answers too!). The advanced modules could use some refactoring.
* A veritable expert: There are many new modules you could start or propose. The Wikibook doesn't have a limited scope. It would be great to cover lots of the more advanced topics.
Please, please, get involved! Chop and change as much as you want. Again, the whole book is on version control, so no change is too drastic.

## Getting in touch

Note that Wikibook contributors can sometimes be found in the #haskell channel on irc.freenode.net. That is a great place to discuss ideas and directions.
There is also a mailing list specific to the Haskell wikibook (and actually all Haskell educational materials). See http://www.haskell.org/pipermail/wikibook/
Below are some notes from past and current contributors about efficient editing of the Wikibook:

## Using Emacs

FIXME: publish this somewhere more sensible
I love Emacs and can't stand using a text area to edit Wikibook pages in, especially long ones where I'm going to be writing a lot. After Firefox crashing on me once or twice and me losing several hours work, I realised there has to be a more sensible way of contributing to MediaWiki projects. This is what I've come up with:

### wikipedia-mode.el

Firstly, wikipedia-mode is essential for font-locking. It's built on outline mode. It does, however, include a few stupid shortcuts, so here is how I have it installed:

### MVS

Now we can edit MediaWiki files in Emacs, it'd be nice to post them back to the server without having to copy-paste into Firefox. A guy called Mark Jaroski wrote MVS, which is a client-side program for interacting with MediaWiki servers. Here's a typical session:
There'll be a new version, 1.0, soonish, which should contain some new features making life a little easier. Here's an extract from an email conversation I've had with him indicating what'll be added:

### VC bindings

Not implemented yet, but in the Big Plan, is to write some VC bindings for Emacs, so committing should be as easy as C-x v v. However, I'm going to wait until some of the aforementioned features are implemented. At the moment, my design for key bindings will be something like:

#### C-x v v, C-c C-f

    Commit file to the server.

#### C-c C-m

    Commit minor version to the server

#### C-c C-p

    Preview the file.
In addition to the VC bindings.

### Fast preview

Most of MVS is slow, but that's okay, because MediaWiki is slow. However, previewing is one area where things could be improved. My plan is to install a local MediaWiki, then have an option in MVS to send preview requests to that server instead of to the remote one, speeding things up. As Mark points out, this is available currently by swapping the .mediawiki files over.
If you've got any ideas, tack them up here.

## Using your favourite text editor

Most of the hints above can be adapted to other text editors. See Text editor support on Wikipedia for details.

## Formatting tips

* A very common problem involves text on the first few lines of a page overlapping with the chapter table of contents in the right side. To fix that, place {{clear}} at the very beginning of the page, just above the chapter TOC.
* A related problem sometimes affects the navigation boxes at the bottom of the page, which can get squeezed to a very narrow width when there are other box templates just above them. Separating the boxes with {{-}} fixes the problem.