diff --git a/doc/developer-guide.md b/doc/developer-guide.md index a532fff01..ac6d3a32d 100644 --- a/doc/developer-guide.md +++ b/doc/developer-guide.md @@ -200,6 +200,46 @@ and the default view given by [bugs.hledger.org](http://bugs.hledger.org) exclud ### Set up for development +1. Download and install [stack](https://github.com/commercialhaskell/stack/wiki/Downloads). + This builds haskell projects and can also install GHC (and on windows, git) if needed. +2. Get the hledger repo: + + ```{.shell .bold} + $ git clone https://github.com/simonmichael/hledger.git + $ cd hledger + ``` + +3. Install optional extra tools (see the Makefile for a list): + + ```shell + $ stack install shelltestrunner hasktags profiteur + ``` + +4. Run `make` or `stack --help` to see some suggested commands: + + ```{.shell .bold} + $ make + Makefile:37: -------------------- hledger make rules -------------------- + Makefile:39: make [help] -- list documented rules in this makefile. make -n RULE shows more detail. + Makefile:204: (INSTALLING:) + Makefile:206: make install -- download dependencies and install hledger executables to ~/.local/bin or equivalent (with stack) + Makefile:231: (BUILDING:) + Makefile:235: make build -- download dependencies and build hledger executables (with stack) + Makefile:304: make hledgerdev -- quickly build the hledger executable (with ghc and -DDEVELOPMENT) + ... + $ stack --help + Available commands: + build Build the project(s) in this directory/configuration + install Build executables and install to a user path + test Build and test the project(s) in this + directory/configuration + bench Build and benchmark the project(s) in this + directory/configuration + ... + ``` + +Old instructions: + 1. Get [GHC](https://www.haskell.org/ghc/) and [cabal-install](http://hackage.haskell.org/package/cabal-install) installed. I recommend the [stackage.org install guide](http://www.stackage.org/install). You can see which GHC versions are officially supported in the `tested-with` field in @@ -235,7 +275,6 @@ and the default view given by [bugs.hledger.org](http://bugs.hledger.org) exclud 6. Install haskell libs required by hledger: ```{.shell .bold} - $ cabal update $ cd hledger $ cabal sandbox init # optional $ make installdeps # or cabal install --only-dep ./hledger-lib ./hledger [./hledger-web] diff --git a/doc/site/download.md b/doc/site/download.md index d79fe89d7..a3bf6bb5e 100644 --- a/doc/site/download.md +++ b/doc/site/download.md @@ -1,6 +1,6 @@ # Download -## I want to download and run +## I want to download and run a recent release @@ -70,20 +70,29 @@ Use cabal
-## I want to build the [latest release](http://hackage.haskell.org/package/hledger) with [GHC](http://haskell.org/ghc) and [cabal](http://haskell.org/cabal/download.html) +## I want to build the [latest release](http://hackage.haskell.org/package/hledger): -`cabal install alex happy` *(if you don't already have these in your path)*\ -`cabal sandbox init; cabal update; cabal install hledger-web` *(use cabal 1.20+)*\ - +Recommended: -Or just cabal install `hledger` if you don't need the web interface.\ -The [Installation Guide](installing.html) describes how to install using cabal in more detail.\ +1. Download and install [stack](https://github.com/commercialhaskell/stack/wiki/Downloads) +2. `stack --resolver nightly-2015-07-13 install hledger [hledger-web]` + +Or: + +1. Install [GHC](http://haskell.org/ghc) and [cabal](http://haskell.org/cabal/download.html) +2. `cabal install alex happy` *(if these are not already in your PATH)* +3. `cabal update` +4. `cabal sandbox init` +5. `cabal install hledger[-web]` + +The old [Installation Guide](installing.html) has more notes on this process. [Release Notes](release-notes.html) shows what's new in the hledger packages. ## I want to build the [latest development version](https://github.com/simonmichael/hledger/commits/master) -`cabal install alex happy` (if you don't already have these in your path)\ -`git clone https://github.com/simonmichael/hledger; cd hledger; make sandbox install` +1. `git clone https://github.com/simonmichael/hledger.git` +2. `cd hledger` +3. `stack install` (or cabal install as shown above) ## I want to run the Ubuntu hledger packages in a virtual machine diff --git a/doc/site/step-by-step.md b/doc/site/step-by-step.md index c784f75aa..5c2d829a7 100644 --- a/doc/site/step-by-step.md +++ b/doc/site/step-by-step.md @@ -27,7 +27,7 @@ Get a command prompt, and run hledger to check the version. It should be reasona ```shell $ hledger --version -hledger 0.23 +hledger 0.26 ``` ## BASIC DATA ENTRY & REPORTING