mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-27 16:15:05 +00:00
45 lines
908 B
Nix
45 lines
908 B
Nix
{ lib
|
|
, buildPythonPackage
|
|
, fetchFromGitHub
|
|
, pytestCheckHook
|
|
, pythonOlder
|
|
, simpleeval
|
|
, wcmatch
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "casbin";
|
|
version = "1.18.2";
|
|
format = "setuptools";
|
|
|
|
disabled = pythonOlder "3.6";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = pname;
|
|
repo = "pycasbin";
|
|
rev = "refs/tags/v${version}";
|
|
hash = "sha256-oI+w9EoNgKnR+7pgvwTmsRpOQI0TxzCx8TjfSEmO7mc=";
|
|
};
|
|
|
|
propagatedBuildInputs = [
|
|
simpleeval
|
|
wcmatch
|
|
];
|
|
|
|
nativeCheckInputs = [
|
|
pytestCheckHook
|
|
];
|
|
|
|
pythonImportsCheck = [
|
|
"casbin"
|
|
];
|
|
|
|
meta = with lib; {
|
|
description = "Authorization library that supports access control models like ACL, RBAC and ABAC";
|
|
homepage = "https://github.com/casbin/pycasbin";
|
|
changelog = "https://github.com/casbin/pycasbin/blob/v${version}/CHANGELOG.md";
|
|
license = licenses.asl20;
|
|
maintainers = with maintainers; [ costrouc ];
|
|
};
|
|
}
|