Skip to content
Snippets Groups Projects
Commit 49696f70 authored by Jean-Paul Calderone's avatar Jean-Paul Calderone
Browse files

Merge branch 'customize-shellhook' into 'main'

add a `shellHook` parameter to `devShells`

See merge request jcalderone/hs-flake-utils!2
parents a51e591b 3d2a383e
Branches
No related tags found
No related merge requests found
...@@ -41,9 +41,16 @@ rec { ...@@ -41,9 +41,16 @@ rec {
# A function that accepts a package set and returns a list of additional # A function that accepts a package set and returns a list of additional
# buildInputs to include in the dev shell. # buildInputs to include in the dev shell.
extraBuildInputs ? (pkgs: []) extraBuildInputs ? (pkgs: [])
, shellHook ? "# nothing"
}: { }: {
default = hsPkgs.shellFor { default = hsPkgs.shellFor {
inherit (preCommitCheck { }) shellHook; shellHook = ''
# Pre-commit
${(preCommitCheck { }).shellHook}
# Application-supplied
${shellHook}
'';
# Packages to create this development shell for. These are usually your # Packages to create this development shell for. These are usually your
# local packages. # local packages.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment