From 63536a698f7cbe8dbd88776025a071a2860872e2 Mon Sep 17 00:00:00 2001 From: Harinn Date: Sun, 19 Jul 2026 00:23:27 +0700 Subject: [PATCH 1/2] python3Packages.grip: migrate to pyproject --- pkgs/development/python-modules/grip/default.nix | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/grip/default.nix b/pkgs/development/python-modules/grip/default.nix index 1a689426877d..0177921aab79 100644 --- a/pkgs/development/python-modules/grip/default.nix +++ b/pkgs/development/python-modules/grip/default.nix @@ -4,6 +4,7 @@ fetchpatch, # Python bits: buildPythonPackage, + setuptools, pytest, responses, docopt, @@ -18,7 +19,7 @@ buildPythonPackage rec { pname = "grip"; version = "4.6.1"; - format = "setuptools"; + pyproject = true; src = fetchFromGitHub { owner = "joeyespo"; @@ -36,12 +37,14 @@ buildPythonPackage rec { }) ]; + build-system = [ setuptools ]; + nativeCheckInputs = [ pytest responses ]; - propagatedBuildInputs = [ + dependencies = [ docopt flask markdown From 624bfc3588eb246352778fd16a30ff037c919a2f Mon Sep 17 00:00:00 2001 From: Harinn Date: Sun, 19 Jul 2026 00:29:23 +0700 Subject: [PATCH 2/2] python3Packages.grip: modernize --- pkgs/development/python-modules/grip/default.nix | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/pkgs/development/python-modules/grip/default.nix b/pkgs/development/python-modules/grip/default.nix index 0177921aab79..56f25b285b23 100644 --- a/pkgs/development/python-modules/grip/default.nix +++ b/pkgs/development/python-modules/grip/default.nix @@ -16,15 +16,17 @@ tabulate, }: -buildPythonPackage rec { +buildPythonPackage (finalAttrs: { pname = "grip"; version = "4.6.1"; pyproject = true; + __structuredAttrs = true; + src = fetchFromGitHub { owner = "joeyespo"; repo = "grip"; - rev = "v${version}"; + tag = "v${finalAttrs.version}"; hash = "sha256-CHL2dy0H/i0pLo653F7aUHFvZHTeZA6jC/rwn1KrEW4="; }; @@ -59,6 +61,8 @@ buildPythonPackage rec { py.test -xm "not assumption" ''; + pythonImportsCheck = [ "grip" ]; + meta = { description = "Preview GitHub Markdown files like Readme locally before committing them"; mainProgram = "grip"; @@ -66,4 +70,4 @@ buildPythonPackage rec { license = lib.licenses.mit; maintainers = with lib.maintainers; [ koral ]; }; -} +})