on master help sign in
Update the readme
commite2a20217ddcd2d0734eba8b36b15bc71d7167615 authormrkkrp <mark.karpov@tweag.io> dateFri 31 May 2019, 14:37 (7 years ago) parent34b9b71
1 file changed+23−17
README.md+23−17
README.md+23−17
@@ -26,23 +26,25 @@ the following features in mind:
2626
2727## Building
2828
29−Ormolu builds with `cabal-install` and `ghc-8.4`. For instance:
29+The easiest way to build the project is with Nix:
3030
31−```bash
32−$ nix-shell -p haskell.compiler.ghc844
33−<inside shell>
34−$ cabal new-update
35−$ cabal new-build
31+```console
32+$ nix-build
33+```
34+
35+Or with `cabal-install` from the Nix shell:
36+
37+```console
38+$ nix-shell --run "cabal new-build"
3639```
3740
3841Alternatively, `stack` could be used with a `stack.yaml` file as follows.
39−```bash
42+
43+```console
4044$ cat stack.yaml
41−resolver: lts-12.26
45+resolver: lts-13.19
4246packages:
4347- '.'
44−extra-deps:
45−- path-io-1.4.2
4648
4749$ stack build
4850```
@@ -50,18 +52,21 @@ $ stack build
5052## Usage
5153
5254The following will print the formatted output to the standard output.
53−```bash
55+
56+```console
5457$ ormolu Module.hs
5558```
5659
5760Add `--mode inplace` to replace the contents of the input file with the
5861formatted output.
59−```bash
62+
63+```console
6064$ ormolu --mode inplace Module.hs
6165```
6266
6367A configuration file can specify the language extensions to use by default.
64−```bash
68+
69+```console
6570$ cat ormolu.yaml
6671ghc-opts:
6772 - -XLambdaCase
@@ -82,10 +87,10 @@ welcome.
8287
8388Right now there are two options for people who want to contribute:
8489
85−* Implementing rendering of AST. This is the main focus right now because we
86− want to have a MVP which can render all syntactical constructions found in
87− Haskell source code. Once that is achieved we'll polish the tool
88− iteratively.
90+* [Implementing rendering of AST][cover-ast]. This is the main focus right
91+ now because we want to have a MVP which can render all syntactical
92+ constructions found in Haskell source code. Once that is achieved we'll
93+ polish the tool iteratively.
8994* [Fixing bugs][bugs]. If this seems more interesting than implementing
9095 rendering of AST, you are welcome to do this as well.
9196
@@ -138,4 +143,5 @@ Copyright © 2018–2019 Tweag I/O
138143
139144[haskell-src-exts]: https://hackage.haskell.org/package/haskell-src-exts
140145[hindent]: https://hackage.haskell.org/package/hindent
146+[cover-ast]: https://github.com/tweag/ormolu/issues?q=is%3Aissue+is%3Aopen+label%3Acovering-ghc-ast
141147[bugs]: https://github.com/tweag/ormolu/issues?q=is%3Aissue+is%3Aopen+label%3Abug