mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-04 04:46:43 +00:00
755b915a15
nix run nixpkgs#silver-searcher -- -G '\.nix$' -0l 'description.*"[Aa]n?' pkgs \ | xargs -0 nix run nixpkgs#gnused -- -i '' -Ee 's/(description.*")[Aa]n? (.)/\1\U\2/'
51 lines
1.1 KiB
Nix
51 lines
1.1 KiB
Nix
{ lib
|
|
, stdenv
|
|
, fetchFromGitHub
|
|
|
|
, python3
|
|
, ghostscript
|
|
, pdftk
|
|
, poppler_utils
|
|
, makeBinaryWrapper
|
|
}:
|
|
|
|
let
|
|
python = python3.withPackages (ps: with ps; [ tkinter ]);
|
|
binPath = lib.makeBinPath [ ghostscript pdftk poppler_utils ];
|
|
in
|
|
stdenv.mkDerivation {
|
|
pname = "pdf-sign";
|
|
version = "0-unstable-2023-08-08";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "svenssonaxel";
|
|
repo = "pdf-sign";
|
|
rev = "98742c6b12ebe2ca3ba375c695f43b52fe38b362";
|
|
hash = "sha256-5GRk0T1iLqmvWI8zvZE3OWEHPS0/zN/Ie9brjZiFpqc=";
|
|
};
|
|
|
|
nativeBuildInputs = [ makeBinaryWrapper ];
|
|
|
|
buildInputs = [ python ];
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
|
|
install -Dm755 pdf-sign pdf-create-empty -t $out/bin
|
|
wrapProgram $out/bin/pdf-sign --prefix PATH : ${binPath}
|
|
wrapProgram $out/bin/pdf-create-empty --prefix PATH : ${binPath}
|
|
|
|
runHook postInstall
|
|
'';
|
|
|
|
meta = {
|
|
description = "Tool to visually sign PDF files";
|
|
homepage = "https://github.com/svenssonaxel/pdf-sign";
|
|
license = lib.licenses.mit;
|
|
mainProgram = "pdf-sign";
|
|
maintainers = with lib.maintainers; [ tomasajt ];
|
|
platforms = lib.platforms.unix;
|
|
};
|
|
}
|
|
|