about summary refs log tree commit diff
path: root/pkgs/development/haskell-modules/configuration-nix.nix
diff options
context:
space:
mode:
authorsternenseemann <sternenseemann@systemli.org>2023-07-11 18:56:03 +0200
committersternenseemann <sternenseemann@systemli.org>2023-07-11 18:56:03 +0200
commitfc97e60a594ee6aee5aacfe46098661b70c83e0c (patch)
treec79baec80463ebc8e8129b2a66407bb46baa2d84 /pkgs/development/haskell-modules/configuration-nix.nix
parent58296ad35526e23b4ba9b1acedd84ac70df045dd (diff)
haskellPackages.shelly: fix test script execution
Due to the lack of /usr/bin/env we need to make the script executable
and throw patchShebangs against it /before/ tests are executed.
Diffstat (limited to 'pkgs/development/haskell-modules/configuration-nix.nix')
-rw-r--r--pkgs/development/haskell-modules/configuration-nix.nix8
1 files changed, 8 insertions, 0 deletions
diff --git a/pkgs/development/haskell-modules/configuration-nix.nix b/pkgs/development/haskell-modules/configuration-nix.nix
index 95238591c6e2d..a0cfa82795157 100644
--- a/pkgs/development/haskell-modules/configuration-nix.nix
+++ b/pkgs/development/haskell-modules/configuration-nix.nix
@@ -341,6 +341,14 @@ self: super: builtins.intersectAttrs super {
   gtksourceview2 = addPkgconfigDepend pkgs.gtk2 super.gtksourceview2;
   gtk-traymanager = addPkgconfigDepend pkgs.gtk3 super.gtk-traymanager;
 
+  shelly = overrideCabal (drv: {
+    # /usr/bin/env is unavailable in the sandbox
+    preCheck = drv.preCheck or "" + ''
+      chmod +x ./test/data/*.sh
+      patchShebangs --build test/data
+    '';
+  }) super.shelly;
+
   # Add necessary reference to gtk3 package
   gi-dbusmenugtk3 = addPkgconfigDepend pkgs.gtk3 super.gi-dbusmenugtk3;