pkgs/d2: add unstable version
This commit is contained in:
parent
50bb6b14a5
commit
e3555cf2cb
2 changed files with 34 additions and 1 deletions
|
@ -13,7 +13,7 @@
|
||||||
final: prev:
|
final: prev:
|
||||||
final.setAttrByPath [ name ] (mkPackage name prev);
|
final.setAttrByPath [ name ] (mkPackage name prev);
|
||||||
|
|
||||||
allPackageNames = [ "d2" ];
|
allPackageNames = [ "d2" "d2_unstable" ];
|
||||||
mkAllPackages = pkgs':
|
mkAllPackages = pkgs':
|
||||||
listToAttrs
|
listToAttrs
|
||||||
(map
|
(map
|
||||||
|
|
33
pkgs/d2_unstable.nix
Normal file
33
pkgs/d2_unstable.nix
Normal file
|
@ -0,0 +1,33 @@
|
||||||
|
{ lib
|
||||||
|
, buildGoModule
|
||||||
|
, fetchFromGitHub
|
||||||
|
, installShellFiles
|
||||||
|
}:
|
||||||
|
|
||||||
|
let version = "2022-11-30"; in
|
||||||
|
|
||||||
|
buildGoModule {
|
||||||
|
pname = "d2";
|
||||||
|
inherit version;
|
||||||
|
|
||||||
|
src = fetchFromGitHub {
|
||||||
|
owner = "terrastruct";
|
||||||
|
repo = "d2";
|
||||||
|
rev = "e6c7d066164040098d294c00779a2248c402c864";
|
||||||
|
sha256 = "sha256-Qlm5i7l4/ZdVulXVOyry3cwZp7bIDbCXUZ5PngpD9bM=";
|
||||||
|
};
|
||||||
|
|
||||||
|
vendorSha256 = "sha256-yNaocc1iaOHlLqDLql+3XWL9j0RoxBXSWATi7QCNgJI=";
|
||||||
|
|
||||||
|
ldflags = [
|
||||||
|
"-s"
|
||||||
|
"-w"
|
||||||
|
"-X oss.terrastruct.com/d2/lib/version.Version=${version}"
|
||||||
|
];
|
||||||
|
|
||||||
|
nativeBuildInputs = [ installShellFiles ];
|
||||||
|
|
||||||
|
postInstall = "installManPage ci/release/template/man/d2.1";
|
||||||
|
|
||||||
|
subPackages = [ "cmd/d2" ];
|
||||||
|
}
|
Loading…
Reference in a new issue