57 lines
1.2 KiB
Nix
57 lines
1.2 KiB
Nix
|
{
|
||
|
lib,
|
||
|
stdenv,
|
||
|
buildPythonPackage,
|
||
|
cryptography,
|
||
|
fetchFromGitHub,
|
||
|
pyspnego,
|
||
|
pytest-mock,
|
||
|
pytestCheckHook,
|
||
|
pythonOlder,
|
||
|
}:
|
||
|
|
||
|
buildPythonPackage rec {
|
||
|
pname = "smbprotocol";
|
||
|
version = "1.14.0";
|
||
|
format = "setuptools";
|
||
|
|
||
|
disabled = pythonOlder "3.7";
|
||
|
|
||
|
src = fetchFromGitHub {
|
||
|
owner = "jborean93";
|
||
|
repo = "smbprotocol";
|
||
|
rev = "refs/tags/v${version}";
|
||
|
hash = "sha256-9J6p3rJeD6ZTOiumUQ7XX7nHI4mC3Sf+Gc+Fw2vwVk4=";
|
||
|
};
|
||
|
|
||
|
propagatedBuildInputs = [
|
||
|
cryptography
|
||
|
pyspnego
|
||
|
];
|
||
|
|
||
|
nativeCheckInputs = [
|
||
|
pytest-mock
|
||
|
pytestCheckHook
|
||
|
];
|
||
|
|
||
|
disabledTests = lib.optionals stdenv.hostPlatform.isDarwin [
|
||
|
# https://github.com/jborean93/smbprotocol/issues/119
|
||
|
"test_copymode_local_to_local_symlink_dont_follow"
|
||
|
"test_copystat_local_to_local_symlink_dont_follow_fail"
|
||
|
|
||
|
# fail in sandbox due to networking
|
||
|
"test_small_recv"
|
||
|
"test_recv_"
|
||
|
];
|
||
|
|
||
|
pythonImportsCheck = [ "smbprotocol" ];
|
||
|
|
||
|
meta = with lib; {
|
||
|
description = "Python SMBv2 and v3 Client";
|
||
|
homepage = "https://github.com/jborean93/smbprotocol";
|
||
|
changelog = "https://github.com/jborean93/smbprotocol/releases/tag/v${version}";
|
||
|
license = with licenses; [ mit ];
|
||
|
maintainers = with maintainers; [ fab ];
|
||
|
};
|
||
|
}
|