[![Build Status](https://travis-ci.org/vu3rdd/functorrent.svg?branch=master)](https://travis-ci.org/vu3rdd/functorrent)
-## building
+## Building
-I suggest using cabal sandbox.
+Functorrent can be build with [Cabal](https://www.haskell.org/cabal/) sandbox or
+[Nix](https://nixos.org/nix/).
-Or you can use Nix pkg, in which case, typing `nix-shell' at the root of the
-source code repo should drop you into a shell which has all the package
-dependencies installed.
+### Cabal sandbox
-### Steps:
+Sandboxes give you per project independent containers, just like Python's
+virtualenv.
-clone the repo; cd functorrent;
+ $ git clone https://github.com/vu3rdd/functorrent && cd functorrent
$ cabal sandbox init
- $ wget http://www.stackage.org/lts/cabal.config
$ cabal install --only-dependencies --enable-tests
$ cabal build # binaries in ./dist/built/functorrent/*
+### Building with Nix
+
+``$ nix-shell``` at the root of the source code repo should drop you into a
+shell which has all the package dependencies installed.
+
+
+ $ nix-shell --pure
+ [...]
+ [nix-shell] $ cabal configure && cabal build
+
## Goals
- Become more profient with Haskell.
- Implement something non-trivial with Haskell (crypto, file operations, network
operations, concurrency, bit twiddling, DHT).
-- Follow the spec - https://wiki.theory.org/BitTorrentSpecification
+- Follow the spec ([official spec](http://bittorrent.org/beps/bep_0003.html), [unofficial spec](https://wiki.theory.org/BitTorrentSpecification))
- Easy for newbies like me to read and understand along side the spec.
- doctest and quickcheck tests.
- Follow Haskell Style Guide - https://github.com/tibbe/haskell-style-guide/blob/master/haskell-style.md