mirror of
https://github.com/trezor/trezor-firmware.git
synced 2024-11-22 07:28:10 +00:00
python: allow nix build from directory (#781)
This commit is contained in:
parent
ffea791658
commit
2e8df889dc
20
python/default.nix
Normal file
20
python/default.nix
Normal file
@ -0,0 +1,20 @@
|
||||
with import <nixpkgs> {};
|
||||
|
||||
let
|
||||
python = let
|
||||
packageOverrides = self: super: {
|
||||
trezor = super.trezor.overridePythonAttrs(old: rec {
|
||||
version = "master";
|
||||
src = ./.;
|
||||
doCheck = true; # set to false if you want to skip tests
|
||||
checkPhase = ''
|
||||
runHook preCheck
|
||||
pytest --pyargs tests --ignore tests/test_tx_api.py
|
||||
runHook postCheck
|
||||
'';
|
||||
});
|
||||
};
|
||||
in pkgs.python3.override {inherit packageOverrides; self = python;};
|
||||
|
||||
in python.withPackages(ps:[ps.trezor])
|
||||
|
Loading…
Reference in New Issue
Block a user