2021-01-11 08:54:33 +01:00
|
|
|
{ lib, stdenv, fetchFromGitHub, postgresql }:
|
2020-08-17 11:20:00 +02:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "plpgsql_check";
|
2021-03-12 13:04:53 +01:00
|
|
|
version = "1.16.0";
|
2020-08-17 11:20:00 +02:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "okbob";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2021-03-12 13:04:53 +01:00
|
|
|
sha256 = "sha256-ZZvRrt2JaAWruAT4FXB6ChS0jLKpUEDCF2UmAAH4BRQ=";
|
2020-08-17 11:20:00 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ postgresql ];
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
install -D -t $out/lib *.so
|
|
|
|
install -D -t $out/share/postgresql/extension *.sql
|
|
|
|
install -D -t $out/share/postgresql/extension *.control
|
|
|
|
'';
|
|
|
|
|
2021-01-11 08:54:33 +01:00
|
|
|
meta = with lib; {
|
2020-08-17 11:20:00 +02:00
|
|
|
description = "Linter tool for language PL/pgSQL";
|
|
|
|
homepage = "https://github.com/okbob/plpgsql_check";
|
|
|
|
platforms = postgresql.meta.platforms;
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = [ maintainers.marsam ];
|
|
|
|
};
|
|
|
|
}
|