about summary refs log tree commit diff
path: root/nixpkgs/pkgs/tools/networking/http-prompt/default.nix
blob: 02bb42800abf354042c0bdcd7a57f6d6e199df2d (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
{ lib, fetchFromGitHub, python3Packages, httpie }:

python3Packages.buildPythonApplication rec {
  pname = "http-prompt";
  version = "2.1.0";

  src = fetchFromGitHub {
    rev = "v${version}";
    repo = "http-prompt";
    owner = "httpie";
    sha256 = "sha256-e4GyuxCeXYNsnBXyjIJz1HqSrqTGan0N3wxUFS+Hvkw=";
  };

  propagatedBuildInputs = with python3Packages; [
    click
    httpie
    parsimonious
    (python.pkgs.callPackage ../../../development/python-modules/prompt-toolkit/1.nix {})
    pygments
    six
    pyyaml
  ];

  checkPhase = ''
    $out/bin/${pname} --version | grep -q "${version}"
  '';

  meta = with lib; {
    description = "An interactive command-line HTTP client featuring autocomplete and syntax highlighting";
    mainProgram = "http-prompt";
    homepage = "https://github.com/eliangcs/http-prompt";
    license = licenses.mit;
    maintainers = with maintainers; [ matthiasbeyer ];
    platforms = platforms.linux ++ platforms.darwin;
  };
}