diff options
author | Joe Kachmar <me@jkachmar.com> | 2021-01-14 11:36:42 -0500 |
---|---|---|
committer | Joe Kachmar <joseph.kachmar@well.co> | 2021-01-14 11:41:31 -0500 |
commit | 95d0e6c1b8adca3a03c5e79fc1dba84b5c1f68d6 (patch) | |
tree | b0d84178d3ac305862e8b060e92969a0cf4e28df /pkgs/development/haskell-modules/make-package-set.nix | |
parent | 335f1fb25f2f784e496dc4e5560cea7e3414a7a8 (diff) | |
download | nixlib-95d0e6c1b8adca3a03c5e79fc1dba84b5c1f68d6.tar nixlib-95d0e6c1b8adca3a03c5e79fc1dba84b5c1f68d6.tar.gz nixlib-95d0e6c1b8adca3a03c5e79fc1dba84b5c1f68d6.tar.bz2 nixlib-95d0e6c1b8adca3a03c5e79fc1dba84b5c1f68d6.tar.lz nixlib-95d0e6c1b8adca3a03c5e79fc1dba84b5c1f68d6.tar.xz nixlib-95d0e6c1b8adca3a03c5e79fc1dba84b5c1f68d6.tar.zst nixlib-95d0e6c1b8adca3a03c5e79fc1dba84b5c1f68d6.zip |
Adds Haskell generic args builder documentation
Diffstat (limited to 'pkgs/development/haskell-modules/make-package-set.nix')
-rw-r--r-- | pkgs/development/haskell-modules/make-package-set.nix | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/pkgs/development/haskell-modules/make-package-set.nix b/pkgs/development/haskell-modules/make-package-set.nix index c6b9f1021bca..9aa353aac137 100644 --- a/pkgs/development/haskell-modules/make-package-set.nix +++ b/pkgs/development/haskell-modules/make-package-set.nix @@ -323,6 +323,36 @@ in package-set { inherit pkgs stdenv callPackage; } self // { # packages. You should set this to true if you have benchmarks defined # in your local packages that you want to be able to run with cabal benchmark doBenchmark ? false + # An optional function that can modify the generic builder arguments + # for the fake package that shellFor uses to construct its environment. + # + # Example: + # let + # # elided... + # haskellPkgs = pkgs.haskell.packages.ghc884.override (hpArgs: { + # overrides = pkgs.lib.composeExtensions (hpArgs.overrides or (_: _: { })) ( + # _hfinal: hprev: { + # mkDerivation = args: hprev.mkDerivation ({ + # doCheck = false; + # doBenchmark = false; + # doHoogle = true; + # doHaddock = true; + # enableLibraryProfiling = false; + # enableExecutableProfiling = false; + # } // args); + # } + # ); + # }); + # in + # hpkgs.shellFor { + # packages = p: [ p.foo ]; + # genericBuilderArgsModifier = args: args // { doCheck = true; doBenchmark = true }; + # } + # + # This will disable tests and benchmarks for everything in "haskellPkgs" + # (which will invalidate the binary cache), and then re-enable them + # for the "shellFor" environment (ensuring that any test/benchmark + # dependencies for "foo" will be available within the nix-shell). , genericBuilderArgsModifier ? (args: args) , ... } @ args: |