-
Notifications
You must be signed in to change notification settings - Fork 841
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into sig-sign-sdist-and-upload-sign
* master: (96 commits) Revert "Additional helper to get project config dir" Additional helper to get project config dir Add a few items to ChangeLog.md Add stack build options to stack ghci #1186 Always build exes, due to cabal copy limitation Ported stack_and_ghcjs wiki page to doc release script: fix compile warnings Fix/add documentation for bcWorkDir and workDirRel Organize Stack.Types.Config Remove unused functions from Stack.Types.Config Fix building tests/benches in some circumstances Refactor generateHaddockIndex Enhance documentation for Stack.Build.Haddock Fix haddock generation Enhance documentation for System.Process.Read Enhance documentation for System.Process.Run Refactorings using mapMaybeM, forMaybeM and forMaybeA quite a few cosmetic improvements Enhance haddocks for Stack.Build.Execute Revert "Only install exes when they're built" ...
- Loading branch information
Showing
72 changed files
with
2,180 additions
and
1,569 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
# Stack & GHCJS | ||
|
||
To set up and use GHCJS with stack, you should place GHCJS `resolver` in your project's `stack.yaml` (see instructions for [old base](#ghcjs-old-base) and [`master` - a.k.a. improved base](#ghcjs-master-aka-improved-base)). Once this has been done, Stack will use GHCJS for most commands, with the exception of `ghc`, `runghc` and `ide`. (Support for `ghc` and `runghc` will likely be added before the next release - see [#1054](https://github.com/commercialhaskell/stack/issues/1054)). | ||
|
||
After creating a `stack.yaml`, which specifies that ghcjs is to be used (see below), you can have Stack automatically set up and boot GHCJS. Stack must be newer than `0.1.6`: | ||
|
||
``` | ||
$ stack setup | ||
``` | ||
|
||
(this will take a long time) | ||
|
||
## Using a stackage snapshot | ||
|
||
The configurations below use a compiler resolver, which means that you can't use packages from a stackage snapshot. The latest development version (which will probably be released as `0.1.7`) also supports using GHCJS with a stackage snapshot, via a `compiler` field. To use the latest development version, do the following: | ||
|
||
``` | ||
$ stack upgrade --git | ||
``` | ||
|
||
For example, the old-base configuration looks like this: | ||
|
||
```yaml | ||
resolver: lts-3.10 | ||
compiler: ghcjs-0.1.0.20150924_ghc-7.10.2 | ||
compiler-check: match-exact | ||
``` | ||
You can also build existing stack projects which target GHC and instead build them with GHCJS. To do this, invoke stack like this: `stack build --compiler ghcjs-0.1.0.20150924_ghc-7.10.2` | ||
|
||
## Example Configurations | ||
|
||
### GHCJS (old base) | ||
|
||
You can use this resolver for GHCJS (old base) in your `stack.yaml`: | ||
|
||
```yaml | ||
resolver: ghcjs-0.1.0.20150924_ghc-7.10.2 | ||
compiler-check: match-exact | ||
``` | ||
|
||
### GHCJS `master` (a.k.a. improved base) | ||
|
||
To use the master branch, a.k.a improved base, add the following to your `stack.yaml`: | ||
|
||
```yaml | ||
resolver: ghcjs-0.2.0.20151001_ghc-7.10.2 | ||
compiler-check: match-exact | ||
setup-info: | ||
ghcjs: | ||
source: | ||
ghcjs-0.2.0.20151001_ghc-7.10.2: | ||
url: "https://github.com/fizruk/ghcjs/releases/download/v0.2.0.20151001/ghcjs-0.2.0.20151001.tar.gz" | ||
``` | ||
|
||
or for the 2015-10-29 master branch | ||
```yaml | ||
resolver: ghcjs-0.2.0.20151029_ghc-7.10.2 | ||
compiler-check: match-exact | ||
setup-info: | ||
ghcjs: | ||
source: | ||
ghcjs-0.2.0.20151029_ghc-7.10.2: | ||
url: "https://github.com/nrolland/ghcjs/releases/download/v0.2.0.20151029/ghcjs-0.2.0.20151029.tar.gz" | ||
``` | ||
|
||
### Custom installed GHCJS (development branch) | ||
|
||
In order to use a GHCJS installed on your path, just add the following to your `stack.yaml`: | ||
|
||
```yaml | ||
resolver: ghcjs-0.2.0_ghc-7.10.2 | ||
``` | ||
|
||
(Or, `ghcjs-0.1.0_ghc-7.10.2` if you are working with an older version) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.