From bf69b0c03f1e380b127815c2263f1dac5c9d9165 Mon Sep 17 00:00:00 2001 From: lassulus Date: Fri, 28 Aug 2015 16:30:36 +0200 Subject: lass 4: add simpleScript --- lass/4lib/default.nix | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 lass/4lib/default.nix diff --git a/lass/4lib/default.nix b/lass/4lib/default.nix new file mode 100644 index 000000000..21a083d1a --- /dev/null +++ b/lass/4lib/default.nix @@ -0,0 +1,20 @@ +{ lib, pkgs, ... }: + +let + krebs = import ../../krebs/4lib { inherit lib; }; +in + +with krebs; + +krebs // rec { + + simpleScript = name: content: + pkgs.stdenv.mkDerivation { + inherit name; + phases = [ "installPhase" ]; + installPhase = '' + mkdir -p $out/bin + ln -s ${pkgs.writeScript name content} $out/bin/${name} + ''; + }; +} -- cgit v1.2.3