erpnext-nix/python/erpnext.nix

61 lines
994 B
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, pythonRelaxDepsHook
, flit-core
# Core dependencies
, pycountry
, unidecode
, barcodenumber
, rapidfuzz
, holidays
# Integration dependencies
, googlemaps
, plaid-python
, python-youtube
, pypng
}:
let
pinData = import ../srcs/pin.nix;
inherit (pinData) erpnextVersion;
inherit (pinData.hashes) erpnextSrcHash;
in
buildPythonPackage rec {
pname = "erpnext";
version = erpnextVersion;
src = fetchFromGitHub {
owner = "frappe";
repo = pname;
rev = "v${erpnextVersion}";
sha256 = erpnextSrcHash;
};
format = "pyproject";
nativeBuildInputs = [ pythonRelaxDepsHook flit-core ];
pythonRelaxDeps = [
"pycountry"
"rapidfuzz"
"Unidecode"
];
propagatedBuildInputs = [
# Core dependencies
pycountry
unidecode
barcodenumber
rapidfuzz
holidays
# Integration dependencies
googlemaps
plaid-python
python-youtube
# used for QR code generation
pypng
];
}