Skip to content

Commit

Permalink
Add contribution section to docs
Browse files Browse the repository at this point in the history
  • Loading branch information
hasufell committed Mar 16, 2024
1 parent 7f8bb14 commit 3675c6b
Showing 1 changed file with 22 additions and 12 deletions.
34 changes: 22 additions & 12 deletions docs/dev.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,27 @@
# Development
# Development and contribution

All you wanted to know about GHCup development.

## Building

GHCup supports development via cabal and stack. E.g.:

* build via stack: `stack build`
* build via cabal (with whatever GHC version): `cabal build`
* build via cabal reproducibly with a specific GHC version
- GHC 8.10.7: `cabal build --project-file=cabal.ghc8107.project`
- GHC 9.0.2: `cabal build --project-file=cabal.ghc902.project`
- and so on (check supported versions via `ls cabal.ghc+([0-9]).project`)
* build the release binaries: `cabal build --project-file=cabal.project.release`

## Contribution process and expectations

* discuss your idea first before implementing anything
* GHCup is a dictatorship, so the final decisions are made by the author
* we don't manage contributors... you can work on anything you like
* reviews focus on logic and design, not on style and formatting
* remember that features, decisions and bugs are high impact, since GHCup is used in CIs, github workflows, etc.

## Module graph

[![Module graph](./modules_small.svg){: .center style="width:900px"}](./modules_wide.svg)
Expand Down Expand Up @@ -61,17 +81,7 @@ Some light suggestions:
3. use `where` a lot, so the main function body reads like prose
4. documentation is part of the code

## Contributing

GHCup supports development via cabal and stack. E.g.:

* build via stack: `stack build`
* build via cabal (with whatever GHC version): `cabal build`
* build via cabal reproducibly with a specific GHC version
- GHC 8.10.7: `cabal build --project-file=cabal.ghc8107.project`
- GHC 9.0.2: `cabal build --project-file=cabal.ghc902.project`
- and so on (check supported versions via `ls cabal.ghc+([0-9]).project`)
* build the release binaries: `cabal build --project-file=cabal.project.release`
## Common tasks

### Adding a new GHC version

Expand Down

0 comments on commit 3675c6b

Please sign in to comment.