mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-23 14:13:35 +00:00
61 lines
1.0 KiB
Nix
61 lines
1.0 KiB
Nix
{ lib
|
|
, buildPythonApplication
|
|
, fetchPypi
|
|
, installShellFiles
|
|
, mock
|
|
, openstacksdk
|
|
, pbr
|
|
, python-keystoneclient
|
|
, pythonOlder
|
|
, stestr
|
|
}:
|
|
|
|
buildPythonApplication rec {
|
|
pname = "python-swiftclient";
|
|
version = "4.1.0";
|
|
format = "setuptools";
|
|
|
|
disabled = pythonOlder "3.6";
|
|
|
|
src = fetchPypi {
|
|
inherit pname version;
|
|
hash = "sha256-+CKY5KSPfL3WgPJjjIXRynrhp27b4wA20htM16KcCes=";
|
|
};
|
|
|
|
nativeBuildInputs = [
|
|
installShellFiles
|
|
];
|
|
|
|
propagatedBuildInputs = [
|
|
pbr
|
|
python-keystoneclient
|
|
];
|
|
|
|
checkInputs = [
|
|
mock
|
|
openstacksdk
|
|
stestr
|
|
];
|
|
|
|
postInstall = ''
|
|
installShellCompletion --cmd swift \
|
|
--bash tools/swift.bash_completion
|
|
installManPage doc/manpages/*
|
|
'';
|
|
|
|
checkPhase = ''
|
|
stestr run
|
|
'';
|
|
|
|
pythonImportsCheck = [
|
|
"swiftclient"
|
|
];
|
|
|
|
meta = with lib; {
|
|
homepage = "https://github.com/openstack/python-swiftclient";
|
|
description = "Python bindings to the OpenStack Object Storage API";
|
|
license = licenses.asl20;
|
|
maintainers = teams.openstack.members;
|
|
};
|
|
}
|