1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, pytestCheckHook
5}:
6
7buildPythonPackage rec {
8 pname = "pyxbe";
9 version = "unstable-2021-01-10";
10
11 src = fetchFromGitHub {
12 owner = "mborgerson";
13 repo = pname;
14 rev = "a7ae1bb21b02a57783831eb080c1edbafaad1d5d";
15 sha256 = "1cp9a5f41z8j7bzip6nhka8qnxs12v75cdf80sk2nzgf1k15wi2p";
16 };
17
18 checkInputs = [
19 pytestCheckHook
20 ];
21
22 # Update location for run with pytest
23 preCheck = ''
24 substituteInPlace tests/test_load.py \
25 --replace "'xbefiles'" "'tests/xbefiles'"
26 '';
27
28 pythonImportsCheck = [ "xbe" ];
29
30 meta = with lib; {
31 description = "Library to work with XBE files";
32 homepage = "https://github.com/mborgerson/pyxbe";
33 license = with licenses; [ mit ];
34 maintainers = with maintainers; [ fab ];
35 };
36}