1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80
|
# -*- mode: snippet -*-
# name: package url
# key: pu
# --
{ lib
, stdenv
, fetchurl
$1
$2
}:
stdenv.mkDerivation rec {
pname = "$3";
version = "$4";
src = fetchurl {
url = "$5";
sha256 = "${6:\$\{lib.fakeSha256\}}";
};
nativeBuildInputs = [ ${1:$(replace-regexp-in-string " *" " "(subst-char-in-string ?, ? yas-text))} ];
buildInputs = [
${2:$(replace-regexp-in-string " *" " "(subst-char-in-string ?, ? yas-text))}
];
meta = with lib; {
homepage = "https://$7";
description = "$8";
longDescription = ''
$9
'';
license = licenses.${10:$$
(yas-choose-value '(
"agpl3"
"asl20"
"bsd1"
"bsd2"
"bsd3"
"free"
"gpl2"
"gpl2Only"
"gpl2Plus"
"gpl3"
"gpl3Only"
"gpl3Plus"
"isc"
"lgpl21Only"
"lgpl21Plus"
"lgpl2Only"
"lgpl2Plus"
"lgpl3"
"lgpl3Only"
"mit"
"mpl20"
"ofl"
"unfree"
))};
maintainers = with maintainers; [ $11 ];
platforms = platforms.${12:$$
(yas-choose-value '(
"all"
"allBut"
"arm"
"cygwin"
"darwin"
"freebsd"
"gnu"
"i686"
"illumos"
"linux"
"mesaPlatforms"
"mips"
"netbsd"
"none"
"openbsd"
"unix"
"x86"
))};
};
}
|