From 3675c6b16c551b2ad411769ab6d31207e9d1b9c3 Mon Sep 17 00:00:00 2001 From: Julian Ospald Date: Sat, 16 Mar 2024 18:46:38 +0800 Subject: [PATCH] Add contribution section to docs --- docs/dev.md | 34 ++++++++++++++++++++++------------ 1 file changed, 22 insertions(+), 12 deletions(-) diff --git a/docs/dev.md b/docs/dev.md index eefaaef..be69c3d 100644 --- a/docs/dev.md +++ b/docs/dev.md @@ -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) @@ -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