depot/third_party/nixpkgs/pkgs/development/python-modules/solo-python/default.nix
Default email c594a97518 Project import generated by Copybara.
GitOrigin-RevId: 301aada7a64812853f2e2634a530ef5d34505048
2022-10-21 20:38:19 +02:00

61 lines
1.1 KiB
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, pythonOlder
, click
, cryptography
, ecdsa
, fido2
, intelhex
, pyserial
, pyusb
, requests
}:
buildPythonPackage rec {
pname = "solo-python";
version = "0.1.1";
format = "flit";
disabled = pythonOlder "3.6";
src = fetchFromGitHub {
owner = "solokeys";
repo = pname;
rev = version;
sha256 = "sha256-XVPYr7JwxeZfZ68+vQ7a7MNiAfJ2bvMbM3R1ryVJ+OU=";
};
propagatedBuildInputs = [
click
cryptography
ecdsa
fido2
intelhex
pyserial
pyusb
requests
];
preBuild = ''
export HOME=$TMPDIR
'';
pythonImportsCheck = [
"solo"
"solo.cli"
"solo.commands"
"solo.fido2"
"solo.operations"
];
meta = with lib; {
description = "Python tool and library for SoloKeys Solo 1";
homepage = "https://github.com/solokeys/solo1-cli";
maintainers = with maintainers; [ wucke13 ];
license = with licenses; [ asl20 mit ];
# not compatible with fido2 >= 1.0.0
# https://github.com/solokeys/solo1-cli/issues/157
broken = versionAtLeast fido2.version "1.0.0";
};
}