1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 appdirs,
6 click,
7 colorama,
8 intelhex,
9 packaging,
10 pyaml,
11 pyftdi,
12 pyserial,
13 requests,
14 schema,
15}:
16buildPythonPackage rec {
17 pname = "bcf";
18 version = "1.9.1";
19 format = "setuptools";
20
21 src = fetchFromGitHub {
22 owner = "hardwario";
23 repo = "bch-firmware-tool";
24 rev = "v${version}";
25 sha256 = "sha256-xKggVEN3O0umDEt358xc+79/SEVm2peMjfFHGTppTEo=";
26 };
27
28 postPatch = ''
29 sed -ri 's/@@VERSION@@/${version}/g' \
30 bcf/__init__.py setup.py
31 '';
32
33 propagatedBuildInputs = [
34 appdirs
35 click
36 colorama
37 intelhex
38 packaging
39 pyaml
40 pyftdi
41 pyserial
42 requests
43 schema
44 ];
45
46 pythonImportsCheck = [ "bcf" ];
47 doCheck = false; # Project provides no tests
48
49 meta = with lib; {
50 homepage = "https://github.com/hardwario/bch-firmware-tool";
51 description = "HARDWARIO Firmware Tool";
52 mainProgram = "bcf";
53 platforms = platforms.linux;
54 license = licenses.mit;
55 maintainers = with maintainers; [ cynerd ];
56 };
57}