nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 38 lines 634 B view raw
1{ stdenv, unzip, ... }: 2 3let 4 buildMoodlePlugin = 5 a@{ 6 name, 7 src, 8 pluginType, 9 configurePhase ? ":", 10 buildPhase ? ":", 11 buildInputs ? [ ], 12 nativeBuildInputs ? [ ], 13 ... 14 }: 15 stdenv.mkDerivation ( 16 a 17 // { 18 name = name; 19 20 inherit pluginType; 21 inherit configurePhase buildPhase buildInputs; 22 23 nativeBuildInputs = [ unzip ] ++ nativeBuildInputs; 24 25 installPhase = '' 26 runHook preInstall 27 28 mkdir -p "$out" 29 mv * $out/ 30 31 runHook postInstall 32 ''; 33 } 34 ); 35in 36{ 37 inherit buildMoodlePlugin; 38}