From f44a5c7f6ce979e4a279e0d36275c56b3082f191 Mon Sep 17 00:00:00 2001 From: NotAShelf Date: Mon, 11 Mar 2024 05:37:39 +0300 Subject: [PATCH] netscanner: init at 0.4.1 --- pkgs/by-name/ne/netscanner/package.nix | 38 ++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 pkgs/by-name/ne/netscanner/package.nix diff --git a/pkgs/by-name/ne/netscanner/package.nix b/pkgs/by-name/ne/netscanner/package.nix new file mode 100644 index 000000000000..1e2beb336ad3 --- /dev/null +++ b/pkgs/by-name/ne/netscanner/package.nix @@ -0,0 +1,38 @@ +{ lib +, rustPlatform +, fetchFromGitHub +, makeWrapper +, iw +}: +let + pname = "netscanner"; + version = "0.4.1"; +in +rustPlatform.buildRustPackage { + inherit pname version; + + nativeBuildInputs = [ makeWrapper ]; + + src = fetchFromGitHub { + owner = "Chleba"; + repo = "netscanner"; + rev = "refs/tags/v${version}"; + hash = "sha256-E9WQpWqXWIhY1cq/5hqBbNBffe/nFLBelnFPW0tS5Ng="; + }; + + cargoHash = "sha256-G2ePiVmHyZ7a4gn7ZGg5y4lhfbWoWGh4+fG9pMHZueg="; + + postFixup = '' + wrapProgram $out/bin/netscanner \ + --prefix PATH : "${lib.makeBinPath [iw]}" + ''; + + meta = { + description = "Network scanner with features like WiFi scanning, packetdump and more"; + homepage = "https://github.com/Chleba/netscanner"; + changelog = "https://github.com/Chleba/netscanner/releases/tag/v${version}"; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ NotAShelf ]; + mainProgram = "netscanner"; + }; +}