A collection of simple building blocks for a fully-fledged Haskell application
JavaScript Haskell
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
01-json
02-snap
03-config
04-recipe-puppy
05-dsl
06-lens
07-forms
08-heist
09-realtime
.gitignore
README.md
Setup.hs
the-pragmatic-haskeller.cabal

README.md

The Pragmatic Haskeller

A collection of "recipes" (no pun intended) to pragmatically get things done in Haskell. We'll build a simple web application for managing recipes. In particular, we'll focus on:

  • How to parse Json files describing recipes

  • How to automatically convert between Json and Bson for storing recipes inside MongoDB

  • Interfacing with an external API

  • A DSL for describing recipes

Follow the tutorials!

I wrote a complete series on "The School of Haskell":

Installation

cd <episode folder>
cabal install

inside each subfolder to install the desired version. You will need the Haskell Platform installed or at least cabal and cabal install.

Avoid Cabal Hell

Consider using hsenv to work inside an isolate environment everytime:

https://github.com/tmhedberg/hsenv.git

Usage is simple: clone the pragmatic project, cd inside it, then:

hsenv
source .hsenv/bin/activate

Et voilà! Now you can install whatever you like without the risk of polluting your global Cabal installation. Is the trick I use myself; I've installed in the global Cabal only barebone stuff, all the rest lives inside a separate isolated environment! If you have cabal hell inside hsenv, simply delete .hsenv and repeat the steps above; you'll have a brand new environment to spoil!

Running each episode

cabal install
pragmatic

To run the "pragmatic" server.

Show me a demo!

Sure! Here we go: http://ec2-107-22-56-237.compute-1.amazonaws.com:8000