about summary refs log tree commit diff
diff options
context:
space:
mode:
authorSandro <sandro.jaeckel@gmail.com>2023-05-15 10:46:04 +0200
committerGitHub <noreply@github.com>2023-05-15 10:46:04 +0200
commit40541b1a63e3e5ac08024a7d41c32f8aa09d6e26 (patch)
treeff506f8739847dadad801f273a26ec08a911a13b
parentce303f34eee1d8ca0c8a692011f20119dbad10ff (diff)
parent58511b124ef34f1a0c89aa58a7e87a8861bc5700 (diff)
downloadnixlib-40541b1a63e3e5ac08024a7d41c32f8aa09d6e26.tar
nixlib-40541b1a63e3e5ac08024a7d41c32f8aa09d6e26.tar.gz
nixlib-40541b1a63e3e5ac08024a7d41c32f8aa09d6e26.tar.bz2
nixlib-40541b1a63e3e5ac08024a7d41c32f8aa09d6e26.tar.lz
nixlib-40541b1a63e3e5ac08024a7d41c32f8aa09d6e26.tar.xz
nixlib-40541b1a63e3e5ac08024a7d41c32f8aa09d6e26.tar.zst
nixlib-40541b1a63e3e5ac08024a7d41c32f8aa09d6e26.zip
Merge pull request #231868 from figsoda/xdg-base-dirs
-rw-r--r--pkgs/development/python-modules/xdg-base-dirs/default.nix38
-rw-r--r--pkgs/top-level/python-packages.nix2
2 files changed, 40 insertions, 0 deletions
diff --git a/pkgs/development/python-modules/xdg-base-dirs/default.nix b/pkgs/development/python-modules/xdg-base-dirs/default.nix
new file mode 100644
index 000000000000..f2ca5bf0a509
--- /dev/null
+++ b/pkgs/development/python-modules/xdg-base-dirs/default.nix
@@ -0,0 +1,38 @@
+{ lib
+, buildPythonPackage
+, pythonOlder
+, fetchFromGitHub
+, poetry-core
+, pytestCheckHook
+}:
+
+buildPythonPackage rec {
+  pname = "xdg-base-dirs";
+  version = "6.0.0";
+  format = "pyproject";
+
+  disabled = pythonOlder "3.10";
+
+  src = fetchFromGitHub {
+    owner = "srstevenson";
+    repo = "xdg-base-dirs";
+    rev = version;
+    hash = "sha256-yVuruSKv99IZGNCpY9cKwAe6gJNAWjL+Lol2D1/0hiI=";
+  };
+
+  nativeBuildInputs = [
+    poetry-core
+  ];
+
+  nativeCheckInputs = [ pytestCheckHook ];
+
+  pythonImportsCheck = [ "xdg_base_dirs" ];
+
+  meta = with lib; {
+    description = "An implementation of the XDG Base Directory Specification in Python";
+    homepage = "https://github.com/srstevenson/xdg-base-dirs";
+    changelog = "https://github.com/srstevenson/xdg-base-dirs/releases/tag/${src.rev}";
+    license = licenses.isc;
+    maintainers = with maintainers; [ figsoda ];
+  };
+}
diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix
index 641fb4d40820..8d39f1c0558a 100644
--- a/pkgs/top-level/python-packages.nix
+++ b/pkgs/top-level/python-packages.nix
@@ -12994,6 +12994,8 @@ self: super: with self; {
 
   xdg = callPackage ../development/python-modules/xdg { };
 
+  xdg-base-dirs = callPackage ../development/python-modules/xdg-base-dirs { };
+
   xdis = callPackage ../development/python-modules/xdis { };
 
   xdot = callPackage ../development/python-modules/xdot {