rio: 0.0.36 -> 0.0.37
[NixPkgs.git] / pkgs / tools / networking / twa / default.nix
blobab73eae70046ccb0db113ef03ca9c1fd7ab47540
1 { lib
2 , stdenv
3 , fetchFromGitHub
4 , makeWrapper
5 , bash
6 , curl
7 , dnsutils
8 , gawk
9 , jq
10 , ncurses
11 , netcat
14 stdenv.mkDerivation rec {
15   pname = "twa";
16   version = "1.10.0";
18   src = fetchFromGitHub {
19     owner = "trailofbits";
20     repo = "twa";
21     rev = "v${version}";
22     hash = "sha256-8c1o03iwStmhjKHmEXIZGyaSOAJRlOuhu0ERjCO5SHg=";
23   };
25   dontBuild = true;
27   nativeBuildInputs = [ makeWrapper ];
29   buildInputs = [ bash
30                   curl
31                   dnsutils
32                   gawk
33                   jq
34                   netcat ];
36   installPhase = ''
37     runHook preInstall
39     install -Dm 0755 twa "$out/bin/twa"
40     install -Dm 0755 tscore "$out/bin/tscore"
41     install -Dm 0644 twa.1 "$out/share/man/man1/twa.1"
42     install -Dm 0644 README.md "$out/share/doc/twa/README.md"
44     wrapProgram "$out/bin/twa" \
45       --prefix PATH : ${lib.makeBinPath [ curl
46                                           dnsutils
47                                           gawk
48                                           jq
49                                           ncurses
50                                           netcat ]}
52     runHook postInstall
53   '';
55   meta = with lib; {
56     description = "A tiny web auditor with strong opinions";
57     homepage = "https://github.com/trailofbits/twa";
58     license = licenses.mit;
59     maintainers = with maintainers; [ avaq ];
60     platforms = platforms.unix;
61   };