about summary refs log tree commit diff
path: root/pkgs/tools/misc/piston-cli/default.nix
blob: 0309832787a40e4942ff6535f9cb7874bddcde19 (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
{ stdenv, lib, python3Packages, fetchPypi }:

python3Packages.buildPythonApplication rec {
  pname = "piston-cli";
  version = "1.4.3";
  format = "pyproject";

  src = fetchPypi {
    inherit pname version;
    sha256 = "qvDGVJcaMXUajdUQWl4W1dost8k0PsS9XX/o8uQrtfY=";
  };

  propagatedBuildInputs = with python3Packages; [ rich prompt-toolkit requests pygments pyyaml more-itertools ];

  checkPhase = ''
    $out/bin/piston --help > /dev/null
  '';

  nativeBuildInputs = with python3Packages; [
    poetry-core
  ];

  pythonRelaxDeps = [
    "rich"
    "more-itertools"
    "PyYAML"
  ];

  meta = with lib; {
    broken = stdenv.hostPlatform.isDarwin;
    description = "Piston api tool";
    homepage = "https://github.com/Shivansh-007/piston-cli";
    license = licenses.mit;
    maintainers = with maintainers; [ ethancedwards8 ];
    mainProgram = "piston";
  };
}