on master help sign in
Update for cabal 3.0, update streamly version
a74f006Harendra Kumar
INSTALL.md+15−9
@@ -11,21 +11,21 @@ from Hackage to your tool configuration.
11
11
12## Using with `cabal`
12## Using with `cabal`
13
13
14−Make sure you have `cabal` version 2.4 or later installed and you have `ghc`
14+Make sure you have `cabal` version 3.0 or later installed and you have `ghc`
15available in your PATH. Refresh your package list:
15available in your PATH. Refresh your package list:
16
16
17```
17```
18−$ cabal v2-update
18+$ cabal update
19```
19```
20
20
21### Using hackage version in repl
21### Using hackage version in repl
22
22
23```
23```
24# Run repl with the latest version from Hackage
24# Run repl with the latest version from Hackage
25−$ cabal v2-repl --build-depends streamly
25+$ cabal repl --build-depends streamly
26
26
27# Run repl with a specific version from Hackage
27# Run repl with a specific version from Hackage
28−$ cabal v2-repl --build-depends streamly==0.6.1
28+$ cabal repl --build-depends streamly==0.7.1
29```
29```
30
30
31### Using github version in repl
31### Using github version in repl
@@ -55,10 +55,17 @@ library
55Run repl:
55Run repl:
56
56
57```
57```
58−$ cabal v2-repl
58+$ cabal repl
59```
59```
60
60
61−### Compiling with ghc
61+### Using with ghc or ghci
62+
63+Before you can use a package with `ghc` or `ghci` directly you need to install
64+the package:
65+
66+```
67+$ cabal install streamly-0.7.1 --lib
68+```
62
69
63```
70```
64$ cat hello.hs
71$ cat hello.hs
@@ -68,8 +75,7 @@ main = S.runStream $ S.fromListM [putStrLn "hello", putStrLn "world"]
68```
75```
69
76
70```
77```
71−$ cabal v2-install streamly-0.6.1
72−$ ghc -package streamly-0.6.1 hello.hs
78+$ ghc hello.hs
73```
79```
74
80
75### Using in a Project
81### Using in a Project
@@ -77,6 +83,6 @@ $ ghc -package streamly-0.6.1 hello.hs
77Add `streamly` to the `build-depends` section of your library/executable in
83Add `streamly` to the `build-depends` section of your library/executable in
78your `<package>.cabal` file. Appropriate version from Hackage will be picked
84your `<package>.cabal` file. Appropriate version from Hackage will be picked
79depending on the version bounds that you specify. See the `github version in
85depending on the version bounds that you specify. See the `github version in
80−repl` section above for a sample `<package>.cabal` file and optionally the
86+repl` section above for a sample `<package>.cabal` file and optionally use the
81`cabal.project` file if you want to use the development version from github in
87`cabal.project` file if you want to use the development version from github in
82your project.
88your project.