Merge pull request #286170 from fabaff/nmap-parse

nmap-parse: init at 0-unstable-2022-09-26
This commit is contained in:
Fabian Affolter 2024-02-05 20:17:19 +01:00 committed by GitHub
commit 912bba153e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -0,0 +1,48 @@
{ lib
, fetchFromGitHub
, python3
}:
python3.pkgs.buildPythonApplication rec {
pname = "nmap-parse";
version = "0-unstable-2022-09-26";
format = "other";
src = fetchFromGitHub {
owner = "jonny1102";
repo = "nmap-parse";
# https://github.com/jonny1102/nmap-parse/issues/12
rev = "ae270ac9ce05bfbe822dbbb29411adf562d40abf";
hash = "sha256-iaE4a5blbDPaKPRnR46+AfegXOEW88i+z/VIVGCepeM=";
};
propagatedBuildInputs = with python3.pkgs; [
beautifulsoup4
cmd2
colorama
ipy
tabulate
];
installPhase = ''
runHook preInstall
install -Dm 755 "nmap-parse.py" "$out/bin/nmap-parse"
install -vd $out/${python3.sitePackages}/
cp -R modules $out/${python3.sitePackages}
runHook postInstall
'';
# Project has no tests
doCheck = false;
meta = with lib; {
description = "Command line nmap XML parser";
homepage = "https://github.com/jonny1102/nmap-parse";
license = licenses.mit;
maintainers = with maintainers; [ fab ];
mainProgram = "nmap-parse";
};
}