about summary refs log tree commit diff
path: root/nixpkgs/pkgs/applications/version-management/git-publish/default.nix
blob: d84c5f096b8cebcfeca1401073520c38e4b86a28 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
{ lib, stdenv, python, perl, fetchFromGitHub, installShellFiles }:
stdenv.mkDerivation rec {
  pname = "git-publish";
  version = "1.8.2";

  src = fetchFromGitHub {
    owner = "stefanha";
    repo = "git-publish";
    rev = "v${version}";
    hash = "sha256-jjpbr+ZqG4U8/z0PurnXR+IUKQkG3QB8YqhDkH8uu2Y=";
  };

  nativeBuildInputs = [ perl installShellFiles ];
  buildInputs = [ python ];

  installPhase = ''
    runHook preInstall

    install -Dm0755 git-publish $out/bin/git-publish
    pod2man git-publish.pod > git-publish.1
    installManPage git-publish.1

    runHook postInstall
  '';

  meta = {
    description = "Prepare and store patch revisions as git tags";
    license = lib.licenses.mit;
    maintainers = [ lib.maintainers.lheckemann ];
    homepage = "https://github.com/stefanha/git-publish";
    mainProgram = "git-publish";
  };
}