No description
b17b088e3f
Flake lock file updates: • Updated input 'flake-parts': 'github:hercules-ci/flake-parts/dcc36e45d054d7bb554c9cdab69093debd91a0b5' (2023-04-01) → 'github:hercules-ci/flake-parts/006c75898cf814ef9497252b022e91c946ba8e17' (2023-05-08) • Updated input 'flake-parts/nixpkgs-lib': 'github:NixOS/nixpkgs/e3652e0735fbec227f342712f180f4f21f0594f2?dir=lib' (2023-03-30) → 'github:NixOS/nixpkgs/da45bf6ec7bbcc5d1e14d3795c025199f28e0de0?dir=lib' (2023-04-30) • Updated input 'haskell-flake': 'github:srid/haskell-flake/a904caac3e4638f84a28102762bf767dd1ae50c0' (2023-04-28) → 'github:srid/haskell-flake/ebfe70269fce376a7c95d6e9f011e16cbfd29b8d' (2023-05-09) • Updated input 'mission-control': 'github:Platonic-Systems/mission-control/c2f3f0a8dce770c46bfa217270ee5592f3a5ebf5' (2023-04-20) → 'github:Platonic-Systems/mission-control/a0c93bd764a3c25e6999397e9f5f119c1b124e38' (2023-05-09) • Updated input 'nixpkgs': 'github:nixos/nixpkgs/6806b63e824f84b0f0e60b6d660d4ae753de0477' (2023-04-28) → 'github:nixos/nixpkgs/12ba1a5f90b16acdca741ac82d8204b3ec8c2aaf' (2023-05-10) • Updated input 'treefmt-nix': 'github:numtide/treefmt-nix/6d8bea2820630576ad8c3a3bde2c95c38bcc471f' (2023-04-26) → 'github:numtide/treefmt-nix/b44794f94514b61512352a18cd77c710f0005f15' (2023-05-05) Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> |
||
---|---|---|
.github/workflows | ||
.vscode | ||
src | ||
.envrc | ||
.gitattributes | ||
.gitignore | ||
.hlint.yaml | ||
flake.lock | ||
flake.nix | ||
fourmolu.yaml | ||
haskell-template.cabal | ||
hie.yaml | ||
Jenkinsfile | ||
LICENSE | ||
README.md | ||
shell.nix |
haskell-template
Get a Haskell development environment up and running quickly. Thanks to Nix, this template is optimized for a fully reproducible and friendly development environment. It is based on:
- Nix + Flakes (via
github:srid/haskell-flake
) + GHC 9.2 - VSCode + HLS
- fourmolu autoformatting
- Relude as Prelude.
.hlint.yaml
is from relude
- Devshell scripts (
,
prefixed) are provided via mission-control
If you have an existing Haskell project, you should probably use https://github.com/srid/haskell-flake instead.
Getting Started
tldr: Install Nix, enable Flakes, open in VSCode and run , run
.
Full instructions: https://srid.ca/haskell-template/start
Recommended dev environment setup: https://haskell.flake.page/direnv
Tips
- Run
nix flake update
to update all flake inputs. - Run
nix build .#check -L
to run the flake checks. - Run
, fmt
in nix shell to autoformat the project. This uses treefmt. - Run
, docs
to start Hoogle with packages in your cabal file. - Run the application without installing:
nix run github:srid/haskell-template
(ornix run .
from checkout) - Common workflows
- Adding library dependencies in Nix: https://haskell.flake.page/dependency
- Adding tests: https://srid.ca/haskell-template/tests
Discussions
Questions? Ideas? Suggestions? You may post them here: https://github.com/srid/haskell-template/discussions