summary refs log tree commit diff
path: root/pkgs/development/python-modules/art/default.nix
blob: 669b81032be7965a0f8d02880ce0b9f8ecbc22fe (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
{ lib
, buildPythonPackage
, fetchFromGitHub
}:

buildPythonPackage rec {
  pname = "art";
  version = "6.0";
  format = "setuptools";

  src = fetchFromGitHub {
    owner = "sepandhaghighi";
    repo = "art";
    rev = "v${version}";
    hash = "sha256-ZF7UvqJU7KxNccMXL7tsL/s5KYpgGeGqaEATHo4WyNI=";
  };

  pythonImportsCheck = [ "art" ];

  # TypeError: art() missing 1 required positional argument: 'artname'
  checkPhase = ''
    runHook preCheck

    $out/bin/art
    $out/bin/art test
    $out/bin/art test2

    runHook postCheck
  '';

  meta = with lib; {
    description = "ASCII art library for Python";
    homepage = "https://github.com/sepandhaghighi/art";
    changelog = "https://github.com/sepandhaghighi/art/blob/${src.rev}/CHANGELOG.md";
    license = licenses.mit;
    maintainers = with maintainers; [ figsoda ];
  };
}