summaryrefslogtreecommitdiff
path: root/temp-postgres.nix
blob: 86045f48a465bad5315cc962829b84b7743b47ad (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
{ lib, stdenv, postgresql, makeBinaryWrapper }:
stdenv.mkDerivation rec {
  name = "temp-postgres-${version}";
  version = "0.1"; # TODO: set or infer correct version

  src = ./.;

  nativeBuildInputs = [
    makeBinaryWrapper
  ];

  buildInputs = [
    postgresql
  ];

  installPhase = ''
    mkdir -p $out/bin
    cp temp-postgres.sh $out/bin/temp-postgres
    mkdir -p $out/man/man1
    cp temp-postgres.1 $out/man/man1/temp-postgres.1
    wrapProgram $out/bin/temp-postgres --prefix PATH : ${lib.makeBinPath [ postgresql ]}
  '';
}
Generated by cgit. See skreutz.com for my tech blog and contact information.