nixpkgs/pkgs/tools/networking/hurl/default.nix

56 lines
1.2 KiB
Nix
Raw Normal View History

2021-07-22 15:39:51 +00:00
{ lib
, stdenv
2021-07-22 15:39:51 +00:00
, rustPlatform
, fetchFromGitHub
, pkg-config
2021-10-09 01:53:02 +00:00
, python3
, installShellFiles
2021-07-22 15:39:51 +00:00
, libxml2
, openssl
, curl
2021-07-22 15:39:51 +00:00
}:
rustPlatform.buildRustPackage rec {
pname = "hurl";
2022-03-26 22:58:13 +00:00
version = "1.6.1";
2021-07-22 15:39:51 +00:00
src = fetchFromGitHub {
owner = "Orange-OpenSource";
repo = pname;
rev = version;
2022-03-26 22:58:13 +00:00
sha256 = "sha256-ud4ARpiyMcYwPKsLbeK4MMBLzkD/tecF1L1vWyYpKmY=";
2021-07-22 15:39:51 +00:00
};
nativeBuildInputs = [
pkg-config
2021-10-09 01:53:02 +00:00
python3
installShellFiles
2021-07-22 15:39:51 +00:00
];
buildInputs = [
libxml2
openssl
] ++ lib.optionals stdenv.isDarwin [
curl
2021-07-22 15:39:51 +00:00
];
# Tests require network access to a test server
doCheck = false;
2022-03-26 22:58:13 +00:00
cargoSha256 = "sha256-tmHP7xwVce/hh8nX1LO/zwPIlDZkICPMlBjZjuv37xU=";
2021-07-22 15:39:51 +00:00
2021-10-09 01:53:02 +00:00
postInstall = ''
python ci/gen_manpage.py docs/hurl.md > hurl.1
python ci/gen_manpage.py docs/hurlfmt.md > hurlfmt.1
installManPage hurl.1 hurlfmt.1
'';
2021-07-22 15:39:51 +00:00
meta = with lib; {
description = "Command line tool that performs HTTP requests defined in a simple plain text format.";
homepage = "https://hurl.dev/";
2021-10-09 01:53:02 +00:00
changelog = "https://github.com/Orange-OpenSource/hurl/raw/${version}/CHANGELOG.md";
2021-07-22 15:39:51 +00:00
maintainers = with maintainers; [ eonpatapon ];
license = licenses.asl20;
};
}