about summary refs log tree commit diff
path: root/pkgs/development/python-modules/canmatrix/default.nix
blob: 3e07188986d07665da787e0d240b52ab297be3b4 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
{ lib
, buildPythonPackage
, fetchFromGitHub
, python
, lxml
, xlwt
, xlrd
, XlsxWriter
, pyyaml
, future }:

buildPythonPackage rec {
  pname = "canmatrix";
  version = "0.6";

  # uses fetchFromGitHub as PyPi release misses test/ dir
  src = fetchFromGitHub {
    owner = "ebroecker";
    repo = pname;
    rev = version;
    sha256 = "1lb0krhchja2jqfsh5lsfgmqcchs1pd38akvc407jfmll96f4yqz";
  };

  checkPhase = ''
    cd test
    ${python.interpreter} ./test.py
  '';

  propagatedBuildInputs =
    [ lxml
      xlwt
      xlrd
      XlsxWriter
      pyyaml
      future
    ];

  meta = with lib; {
    homepage = https://github.com/ebroecker/canmatrix;
    description = "Support and convert several CAN (Controller Area Network) database formats .arxml .dbc .dbf .kcd .sym fibex xls(x)";
    license = licenses.bsd2;
    maintainers = with maintainers; [ sorki ];
  };
}