summaryrefslogtreecommitdiffstats
path: root/shell.nix
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2025-03-12 19:45:02 +0100
committertv <tv@krebsco.de>2025-03-12 19:45:02 +0100
commit3c5301303230f563214c5ff003f9fc8e2e0a7199 (patch)
treecea7e53e57463fd09bb03d12a36472eed4e3b82d /shell.nix
parentb0a965bfd72d8d7d861a424d9e39c7f923c181bd (diff)
replace Makefile by shell.nixHEADmaster
Diffstat (limited to 'shell.nix')
-rw-r--r--shell.nix21
1 files changed, 21 insertions, 0 deletions
diff --git a/shell.nix b/shell.nix
new file mode 100644
index 0000000..30c2872
--- /dev/null
+++ b/shell.nix
@@ -0,0 +1,21 @@
+{ nixpkgs ? import <nixpkgs> {}, compiler ? "default", doBenchmark ? false }:
+
+let
+
+ inherit (nixpkgs) pkgs;
+
+ haskellPackages = if compiler == "default"
+ then pkgs.haskellPackages
+ else pkgs.haskell.packages.${compiler};
+
+ variant = if doBenchmark then pkgs.haskell.lib.doBenchmark else pkgs.lib.id;
+
+ drv = variant (haskellPackages.callCabal2nix "terminal-scanner" ./. {});
+
+in
+
+ pkgs.lib.overrideDerivation drv.env (oldAttrs: {
+ buildInputs = [
+ pkgs.cabal-install
+ ];
+ })
[cgit] Unable to lock slot /tmp/cgit/41000000.lock: Permission denied (13)