From 2021a4b8703cefe575f4431708b970d219e9983e Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Mon, 17 Aug 2020 04:20:00 -0500 Subject: [PATCH] postgresqlPackages.plpgsql_check: init at 1.13.1 --- .../sql/postgresql/ext/plpgsql_check.nix | 29 +++++++++++++++++++ pkgs/servers/sql/postgresql/packages.nix | 2 ++ 2 files changed, 31 insertions(+) create mode 100644 pkgs/servers/sql/postgresql/ext/plpgsql_check.nix diff --git a/pkgs/servers/sql/postgresql/ext/plpgsql_check.nix b/pkgs/servers/sql/postgresql/ext/plpgsql_check.nix new file mode 100644 index 000000000000..b95ef73308db --- /dev/null +++ b/pkgs/servers/sql/postgresql/ext/plpgsql_check.nix @@ -0,0 +1,29 @@ +{ stdenv, fetchFromGitHub, postgresql }: + +stdenv.mkDerivation rec { + pname = "plpgsql_check"; + version = "1.13.1"; + + src = fetchFromGitHub { + owner = "okbob"; + repo = pname; + rev = "v${version}"; + sha256 = "19vcvfhxh0922qgibahmkyf7czniycqbzccxdw65j1ia7fd8yyc3"; + }; + + 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 + ''; + + meta = with stdenv.lib; { + description = "Linter tool for language PL/pgSQL"; + homepage = "https://github.com/okbob/plpgsql_check"; + platforms = postgresql.meta.platforms; + license = licenses.mit; + maintainers = [ maintainers.marsam ]; + }; +} diff --git a/pkgs/servers/sql/postgresql/packages.nix b/pkgs/servers/sql/postgresql/packages.nix index 44d8ff9cbb88..44e560a5f837 100644 --- a/pkgs/servers/sql/postgresql/packages.nix +++ b/pkgs/servers/sql/postgresql/packages.nix @@ -21,6 +21,8 @@ self: super: { pgroonga = super.callPackage ./ext/pgroonga.nix { }; + plpgsql_check = super.callPackage ./ext/plpgsql_check.nix { }; + plv8 = super.callPackage ./ext/plv8.nix { v8 = super.callPackage ../../../development/libraries/v8/plv8_6_x.nix { python = self.python2;