nixpkgs/pkgs/development/tools/database/schemaspy/default.nix

42 lines
941 B
Nix
Raw Normal View History

2017-11-09 16:16:11 +01:00
{ lib, stdenv, fetchurl, jre, makeWrapper, graphviz }:
stdenv.mkDerivation rec {
2020-01-06 14:02:25 +01:00
version = "6.1.0";
pname = "schemaspy";
2017-11-09 16:16:11 +01:00
src = fetchurl {
url = "https://github.com/schemaspy/schemaspy/releases/download/v${version}/${pname}-${version}.jar";
2020-01-06 14:02:25 +01:00
sha256 = "0lgz6b17hx9857fb2l03ggz8y3n8a37vrcsylif0gmkwj1v4qgl7";
2017-11-09 16:16:11 +01:00
};
2019-06-19 17:45:34 +02:00
dontUnpack = true;
2017-11-09 16:16:11 +01:00
buildInputs = [
jre
];
2017-11-19 16:11:34 +01:00
nativeBuildInputs = [
makeWrapper
];
2017-11-09 16:16:11 +01:00
wrappedPath = lib.makeBinPath [
graphviz
];
2017-11-19 16:11:34 +01:00
installPhase = ''
install -D ${src} "$out/share/java/${pname}-${version}.jar"
2017-11-09 16:16:11 +01:00
2017-11-19 16:11:34 +01:00
makeWrapper ${jre}/bin/java $out/bin/schemaspy \
--add-flags "-jar $out/share/java/${pname}-${version}.jar" \
2017-11-19 16:11:34 +01:00
--prefix PATH : "$wrappedPath"
'';
2017-11-09 16:16:11 +01:00
meta = with lib; {
homepage = "http://schemaspy.org";
description = "Document your database simply and easily";
license = licenses.mit;
maintainers = with maintainers; [ jraygauthier ];
};
}