about summary refs log tree commit diff
path: root/pkgs/by-name/pd
diff options
context:
space:
mode:
authorAleksana2024-06-24 12:24:19 +0800
committerGitHub2024-06-24 12:24:19 +0800
commitf4d4d2ac340b7ede384bf0cf0a31ac174d64ce1b (patch)
treec9a12df82f7bf67fc1413662154b09e23e1e1746 /pkgs/by-name/pd
parent2ee53d800ad85bb7465b02fce59d45fa2eeacb74 (diff)
parente795e679be79a6e7efeffa6aa07254b01709641f (diff)
Merge pull request #278823 from dansbandit/pdftitle
pdftitle: init at 0.11
Diffstat (limited to 'pkgs/by-name/pd')
-rw-r--r--pkgs/by-name/pd/pdftitle/package.nix37
1 files changed, 37 insertions, 0 deletions
diff --git a/pkgs/by-name/pd/pdftitle/package.nix b/pkgs/by-name/pd/pdftitle/package.nix
new file mode 100644
index 000000000000..e3267a58abae
--- /dev/null
+++ b/pkgs/by-name/pd/pdftitle/package.nix
@@ -0,0 +1,37 @@
+{
+  lib,
+  fetchFromGitHub,
+  python3Packages,
+  pdfminer
+}:
+
+python3Packages.buildPythonApplication rec {
+  pname = "pdftitle";
+  version = "0.11";
+  pyproject = true;
+
+  src = fetchFromGitHub {
+    owner = "metebalci";
+    repo = "pdftitle";
+    rev = "v${version}";
+    hash = "sha256-kj1pJpyWRgEaAADF6YqzdD8QnJ6iu0eXFMR4NGM4/+Y=";
+  };
+
+  build-system = with python3Packages; [
+    setuptools
+  ];
+
+  dependencies = with python3Packages; [
+    pdfminer
+  ];
+
+  pythonImportsCheck = [ "pdftitle" ];
+
+  meta = {
+    description = "Utility to extract the title from a PDF file";
+    homepage = "https://github.com/metebalci/pdftitle";
+    license = lib.licenses.gpl3Only;
+    maintainers = with lib.maintainers; [ dansbandit ];
+    mainProgram = "pdftitle";
+  };
+}