diff options
Diffstat (limited to 'pkgs/development/python-modules/bme680/default.nix')
-rw-r--r-- | pkgs/development/python-modules/bme680/default.nix | 43 |
1 files changed, 23 insertions, 20 deletions
diff --git a/pkgs/development/python-modules/bme680/default.nix b/pkgs/development/python-modules/bme680/default.nix index 955eee09cdef..3d1a3c0cd233 100644 --- a/pkgs/development/python-modules/bme680/default.nix +++ b/pkgs/development/python-modules/bme680/default.nix @@ -1,41 +1,44 @@ -{ lib -, buildPythonPackage -, fetchFromGitHub -, mock -, smbus-cffi -, pytestCheckHook +{ + lib, + buildPythonPackage, + fetchFromGitHub, + + # build-system + hatchling, + hatch-fancy-pypi-readme, + + # dependencies + smbus2, + + # checks + mock, + pytestCheckHook, }: buildPythonPackage rec { pname = "bme680"; - version = "1.1.1"; - format = "setuptools"; + version = "2.0.0"; + pyproject = true; src = fetchFromGitHub { owner = "pimoroni"; repo = "bme680-python"; - rev = "v${version}"; - hash = "sha256-gmdRxMJ0DoCyNcb/bYp746PBi4HktHAAYOcSQJ0Uheg="; + rev = "refs/tags/v${version}"; + hash = "sha256-ep0dnok/ycEoUAnOK4QmdqdO0r4ttzSoqHDl7aPengE="; }; - propagatedBuildInputs = [ - smbus-cffi + build-system = [ + hatchling + hatch-fancy-pypi-readme ]; - preBuild = '' - cd library - ''; + dependencies = [ smbus2 ]; nativeCheckInputs = [ mock pytestCheckHook ]; - postPatch = '' - substituteInPlace library/setup.cfg \ - --replace "smbus" "smbus-cffi" - ''; - pythonImportsCheck = [ "bme680" ]; meta = with lib; { |