Skip to content

Commit 4b58372

Browse files
committed
Doc updates for readthedocs.org
1 parent dff260a commit 4b58372

24 files changed

+625
-324
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,4 @@ tags
1919
/*.iml
2020
/src/highlight.js
2121
/src/style.css
22+
/doc/_build

CONTRIBUTING.md

+2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
# Contributors Guide
2+
13
## Bug Reports
24

35
When reporting a bug, please write in the following format:

ChangeLog.md

+5-3
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
1+
# Changelog
2+
13
## 0.1.8.0
24

35
Major changes:
46

57
* GHCJS can now be used with stackage snapshots via the new `compiler` field.
68
* Windows installers are now available:
7-
[download them here](https://github.com/commercialhaskell/stack/blob/release/doc/install_and_upgrade.md#windows)
9+
[download them here](http://docs.haskellstack.org/en/stable/install_and_upgrade.html#windows)
810
[#613](https://github.com/commercialhaskell/stack/issues/613)
911
* Docker integration works with non-FPComplete generated images
1012
[#531](https://github.com/commercialhaskell/stack/issues/531)
@@ -73,7 +75,7 @@ Bug fixes:
7375
* Fix: unlisted files in tests and benchmarks trigger extraneous second build
7476
[#838](https://github.com/commercialhaskell/stack/issues/838)
7577

76-
## v0.1.6.0
78+
## 0.1.6.0
7779

7880
Major changes:
7981

@@ -218,7 +220,7 @@ Major changes:
218220
* Respect TemplateHaskell addDependentFile dependency changes ([#105](https://github.com/commercialhaskell/stack/issues/105))
219221
* TH dependent files are taken into account when determining whether a package needs to be built.
220222
* Overhauled target parsing, added `--test` and `--bench` options [#651](https://github.com/commercialhaskell/stack/issues/651)
221-
* For details, see [Build commands documentation](doc/build_command.md)
223+
* For details, see [Build commands documentation](http://docs.haskellstack.org/en/stable/build_command.html)
222224

223225
Other enhancements:
224226

README.md

+4-197
Original file line numberDiff line numberDiff line change
@@ -4,201 +4,8 @@
44
[![Windows build status](https://ci.appveyor.com/api/projects/status/c1c7uvmw6x1dupcl?svg=true)](https://ci.appveyor.com/project/snoyberg/stack)
55
[![Release](https://img.shields.io/github/release/commercialhaskell/stack.svg)](https://github.com/commercialhaskell/stack/releases)
66

7-
`stack` is a cross-platform program for developing Haskell
8-
projects. It is aimed at Haskellers both new and experienced.
7+
`stack` is a cross-platform program for developing Haskell projects. It is aimed
8+
at Haskellers both new and experienced.
99

10-
<img src="http://i.imgur.com/WW69oTj.gif" width="50%" align="right">
11-
12-
It features:
13-
14-
* Installing GHC automatically, in an isolated location.
15-
* Installing packages needed for your project.
16-
* Building your project.
17-
* Testing your project.
18-
* Benchmarking your project.
19-
20-
#### How to install
21-
22-
Downloads are available by operating system:
23-
24-
* [Windows](https://github.com/commercialhaskell/stack/blob/release/doc/install_and_upgrade.md#windows)
25-
* [Mac OS X](https://github.com/commercialhaskell/stack/blob/release/doc/install_and_upgrade.md#mac-os-x)
26-
* [Ubuntu](https://github.com/commercialhaskell/stack/blob/release/doc/install_and_upgrade.md#ubuntu)
27-
* [Debian](https://github.com/commercialhaskell/stack/blob/release/doc/install_and_upgrade.md#debian)
28-
* [CentOS / Red Hat / Amazon Linux](https://github.com/commercialhaskell/stack/blob/release/doc/install_and_upgrade.md#centos--red-hat--amazon-linux)
29-
* [Fedora](https://github.com/commercialhaskell/stack/blob/release/doc/install_and_upgrade.md#fedora)
30-
* [Arch Linux](https://github.com/commercialhaskell/stack/blob/release/doc/install_and_upgrade.md#arch-linux)
31-
* [NixOS](https://github.com/commercialhaskell/stack/blob/release/doc/install_and_upgrade.md#nixos)
32-
* [Linux (general)](https://github.com/commercialhaskell/stack/blob/release/doc/install_and_upgrade.md#linux)
33-
34-
[Upgrade instructions](https://github.com/commercialhaskell/stack/blob/release/doc/install_and_upgrade.md#upgrade)
35-
36-
Note: if you are using cabal-install to install stack, you may need to pass a
37-
constraint to work around a
38-
[Cabal issue](https://github.com/haskell/cabal/issues/2759): `cabal install
39-
--constraint 'mono-traversable >= 0.9' stack`.
40-
41-
#### Quick Start Guide
42-
43-
First you need to [install it (see previous section)](#how-to-install).
44-
45-
##### Start your new project:
46-
47-
~~~ {.bash}
48-
stack new my-project
49-
cd my-project
50-
stack setup
51-
stack build
52-
stack exec my-project-exe
53-
~~~
54-
55-
- The `stack new` command will create a new directory containing all
56-
the needed files to start a project correctly.
57-
- The `stack setup` will download the compiler if necessary in an isolated
58-
location (default `~/.stack`) that won't interfere with any system-level
59-
installations. (For information on installation paths, please use the `stack
60-
path` command.).
61-
- The `stack build` command will build the minimal project.
62-
- `stack exec my-project-exe` will execute the command.
63-
- If you just want to install an executable using stack, then all you have to do
64-
is`stack install <package-name>`.
65-
66-
If you want to launch a REPL:
67-
68-
~~~ {.bash}
69-
stack ghci
70-
~~~
71-
72-
73-
Run `stack` for a complete list of commands.
74-
75-
##### Workflow
76-
77-
The `stack new` command should have created the following files:
78-
79-
~~~
80-
.
81-
├── LICENSE
82-
├── Setup.hs
83-
├── app
84-
│   └── Main.hs
85-
├── my-project.cabal
86-
├── src
87-
│   └── Lib.hs
88-
├── stack.yaml
89-
└── test
90-
└── Spec.hs
91-
92-
3 directories, 7 files
93-
~~~
94-
95-
So to manage your library:
96-
97-
1. Edit files in the `src/` directory.
98-
99-
The `app` directory should preferably contains only files related to
100-
executables.
101-
102-
2. If you need to include another library (for example the package [`text`](https://hackage.haskell.org/package/text):
103-
104-
- Add the package `text` to the file `my-project.cabal`
105-
in the section `build-depends: ...`.
106-
- run `stack build` another time
107-
108-
3. If you get an error that tells you your package isn't in the LTS.
109-
Just try to add a new version in the `stack.yaml` file in the `extra-deps` section.
110-
111-
It was a really fast introduction on how to start to code in Haskell using `stack`.
112-
If you want to go further, we highly recommend you to read the [`stack` guide](https://github.com/commercialhaskell/stack/blob/release/doc/GUIDE.md).
113-
114-
#### How to contribute
115-
116-
This assumes that you have already installed a version of stack, and have `git`
117-
installed.
118-
119-
1. Clone `stack` from git with
120-
`git clone https://github.com/commercialhaskell/stack.git`.
121-
2. Enter into the stack folder with `cd stack`.
122-
3. Build `stack` using a pre-existing `stack` install with
123-
`stack setup && stack build`.
124-
4. Once `stack` finishes building, check the stack version with
125-
`stack --version`. Make sure the version is the latest.
126-
5. Look for issues tagged with
127-
[`newcomer` and `awaiting-pr` labels](https://github.com/commercialhaskell/stack/issues?q=is%3Aopen+is%3Aissue+label%3Anewcomer+label%3A%22awaiting+pr%22)
128-
129-
Build from source as a one-liner:
130-
131-
```bash
132-
git clone https://github.com/commercialhaskell/stack.git && \
133-
cd stack && \
134-
stack setup && \
135-
stack build
136-
```
137-
138-
#### Complete guide to stack
139-
140-
This repository also contains a complete [user guide to using stack
141-
](https://github.com/commercialhaskell/stack/blob/release/doc/GUIDE.md), covering all of the most common use cases.
142-
143-
144-
#### Questions, Feedback, Discussion
145-
146-
* For frequently asked questions about detailed or specific use-cases, please
147-
see [the FAQ](https://github.com/commercialhaskell/stack/blob/release/doc/faq.md).
148-
* For general questions, comments, feedback and support please write
149-
to [the stack mailing list](https://groups.google.com/d/forum/haskell-stack).
150-
* For bugs, issues, or requests please
151-
[open an issue](https://github.com/commercialhaskell/stack/issues/new).
152-
* When using Stack Overflow, please use [the haskell-stack
153-
tag](http://stackoverflow.com/questions/tagged/haskell-stack).
154-
155-
#### Why stack?
156-
157-
stack is a project of the [Commercial Haskell](http://commercialhaskell.com/)
158-
group, spearheaded by [FP Complete](https://www.fpcomplete.com/). It is
159-
designed to answer the needs of commercial Haskell users, hobbyist Haskellers,
160-
and individuals and companies thinking about starting to use Haskell. It is
161-
intended to be easy to use for newcomers, while providing the customizability
162-
and power experienced developers need.
163-
164-
While stack itself has been around since June of 2015, it is based on codebases
165-
used by FP Complete for its corporate customers and internally for years prior.
166-
stack is a refresh of that codebase combined with other open source efforts
167-
like [stackage-cli](https://github.com/fpco/stackage-cli) to meet the needs of
168-
users everywhere.
169-
170-
A large impetus for the work on stack was a [large survey of people interested
171-
in
172-
Haskell](https://www.fpcomplete.com/blog/2015/05/thousand-user-haskell-survey),
173-
which rated build issues as a major concern. The stack team hopes that stack
174-
can address these concerns.
175-
176-
<hr>
177-
178-
## Documentation Table Of Contents
179-
180-
* Project Documentation
181-
* [Maintainer Guide](https://github.com/commercialhaskell/stack/blob/release/doc/MAINTAINER_GUIDE.md): includes releasing information
182-
* [Signing Key](https://github.com/commercialhaskell/stack/blob/release/doc/SIGNING_KEY.md): downloadable stack binaries are signed
183-
with this key
184-
* Tool Documentation
185-
* [Build Command](https://github.com/commercialhaskell/stack/blob/release/doc/build_command.md): reference for the syntax of the
186-
build command and the command line targets
187-
* [Dependency Visualization](https://github.com/commercialhaskell/stack/blob/release/doc/dependency_visualization.md): uses Graphviz
188-
* [Docker Integration](https://github.com/commercialhaskell/stack/blob/release/doc/docker_integration.md)
189-
* [FAQ](https://github.com/commercialhaskell/stack/blob/release/doc/faq.md): frequently asked questions about detailed or specific
190-
use-cases
191-
* [Install/Upgrade](https://github.com/commercialhaskell/stack/blob/release/doc/install_and_upgrade.md): a list of downloads
192-
available by operating system, installation instructions, and upgrade
193-
instructions
194-
* [Nonstandard Project Initialization](https://github.com/commercialhaskell/stack/blob/release/doc/nonstandard_project_init.md)
195-
* [Shell Autocompletion](https://github.com/commercialhaskell/stack/blob/release/doc/shell_autocompletion.md)
196-
* [User Guide](https://github.com/commercialhaskell/stack/blob/release/doc/GUIDE.md): in-depth tutorial covering the most common use
197-
cases and all major stack features (requires no prior Haskell tooling
198-
experience)
199-
* [YAML Configuration](https://github.com/commercialhaskell/stack/blob/release/doc/yaml_configuration.md): reference for writing
200-
`stack.yaml` files
201-
* Advanced Documentation
202-
* [Architecture](https://github.com/commercialhaskell/stack/blob/release/doc/architecture.md): reference for people curious about
203-
stack internals, wanting to get involved deeply in the codebase, or
204-
wanting to use stack in unusual ways
10+
See [haskellstack.org](http://haskellstack.org) or the `doc` directory for more
11+
information.

doc/CONTRIBUTING.md

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../CONTRIBUTING.md

doc/ChangeLog.md

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../ChangeLog.md

doc/GUIDE.md

+13-11
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
# User guide
2+
13
stack is a modern, cross-platform build tool for Haskell code.
24

35
This guide takes a new stack user through the typical workflows. This guide
@@ -46,7 +48,7 @@ all commands work cross-platform, unless explicitly stated otherwise.
4648
## Downloading and Installation
4749

4850
The [documentation dedicated to downloading
49-
stack](install_and_upgrade.md) has the most
51+
stack](install_and_upgrade.html) has the most
5052
up-to-date information for a variety of operating systems, including multiple
5153
GNU/Linux flavors. Instead of repeating that content here, please go check out
5254
that page and come back here when you can successfully run `stack --version`.
@@ -389,7 +391,7 @@ containing the module in question is not available. To tell stack to use text,
389391
you need to add it to your .cabal file — specifically in your build-depends
390392
section, like this:
391393
392-
```cabal
394+
```
393395
library
394396
hs-source-dirs: src
395397
exposed-modules: Lib
@@ -617,7 +619,7 @@ At the time of writing:
617619
* Experimental custom snapshot support
618620

619621
The most up-to-date information can always be found in the
620-
[stack.yaml documentation](yaml_configuration.md#resolver).
622+
[stack.yaml documentation](yaml_configuration.html#resolver).
621623

622624
## Existing projects
623625

@@ -723,7 +725,7 @@ Please choose one of the following commands to get started.
723725
stack init --resolver lts-2.22
724726
725727
You'll then need to add some extra-deps. See the
726-
[stack.yaml documentation](yaml_configuration.md#extra-deps).
728+
[stack.yaml documentation](yaml_configuration.html#extra-deps).
727729
728730
You can also try falling back to a dependency solver with:
729731
@@ -1026,7 +1028,7 @@ to build.
10261028

10271029
We're not going to cover the full generality of these arguments here; instead,
10281030
there's [documentation covering the full build command
1029-
syntax](build_command.md).
1031+
syntax](build_command.html).
10301032
Here, we'll just point out a few different types of arguments:
10311033

10321034
* You can specify a *package name*, e.g. `stack build vector`.
@@ -1163,7 +1165,7 @@ In addition to local directories, you can also refer to packages available in a
11631165
Git repository or in a tarball over HTTP/HTTPS. This can be useful for using a
11641166
modified version of a dependency that hasn't yet been released upstream. This is
11651167
a slightly more advanced usage that we won't go into detail with here, but it's
1166-
covered in the [stack.yaml documentation](yaml_configuration.md#packages).
1168+
covered in the [stack.yaml documentation](yaml_configuration.html#packages).
11671169

11681170
## Flags and GHC options
11691171

@@ -1251,7 +1253,7 @@ confusion.
12511253
Final point: if you have GHC options that you'll be regularly passing to your
12521254
packages, you can add them to your stack.yaml file (starting with
12531255
stack-0.1.4.0). See [the documentation section on
1254-
ghc-options](yaml_configuration.md#ghc-options)
1256+
ghc-options](yaml_configuration.html#ghc-options)
12551257
for more information.
12561258

12571259
## path
@@ -1509,9 +1511,9 @@ There are lots of resources available for learning more about stack:
15091511
* `stack --help`
15101512
* `stack --version` — identify the version and Git hash of the stack executable
15111513
* `--verbose` (or `-v`) — much more info about internal operations (useful for bug reports)
1512-
* The [README](https://github.com/commercialhaskell/stack#readme)
1514+
* The [home page](http://haskellstack.org)
15131515
* The [stack mailing list](https://groups.google.com/d/forum/haskell-stack)
1514-
* The [the FAQ](faq.md)
1516+
* The [the FAQ](faq.html)
15151517
* The [stack wiki](https://github.com/commercialhaskell/stack/wiki)
15161518
* The [haskell-stack tag on Stack Overflow](http://stackoverflow.com/questions/tagged/haskell-stack)
15171519
* [Another getting started with stack tutorial](http://seanhess.github.io/2015/08/04/practical-haskell-getting-started.html)
@@ -1568,7 +1570,7 @@ getting type information in Emacs. For more information, see
15681570
15691571
If you'd like to get some insight into the dependency tree of your packages, you
15701572
can use the `stack dot` command and Graphviz. More information is
1571-
[available in the Dependency visualization documentation](dependency_visualization.md).
1573+
[available in the Dependency visualization documentation](dependency_visualization.html).
15721574
15731575
### Travis with caching
15741576
@@ -1654,7 +1656,7 @@ code inside a Docker image, which means:
16541656
a large initial download, but much faster builds
16551657

16561658
For more information, see
1657-
[the Docker-integration documentation](docker_integration.md).
1659+
[the Docker-integration documentation](docker_integration.html).
16581660

16591661
stack can also generate Docker images for you containing your built executables.
16601662
This feature is great for automating deployments from CI. This feature is not

0 commit comments

Comments
 (0)