wifish: init at 1.1.4

This commit is contained in:
AndersonTorres 2021-01-02 22:47:40 -03:00
parent 5ccb5d4ca3
commit 12338f6ca8
2 changed files with 49 additions and 0 deletions

View File

@ -0,0 +1,47 @@
{ stdenv, fetchFromGitHub
, dialog
, gawk
, wpa_supplicant
, makeWrapper
}:
stdenv.mkDerivation rec {
pname = "wifish";
version = "1.1.4";
src = fetchFromGitHub{
owner = "bougyman";
repo = "wifish";
rev = version;
sha256 = "sha256-eTErN6CfKDey/wV+9o9cBVaG5FzCRBiA9UicrMz3KBc=";
};
nativeBuildInputs = [ makeWrapper ];
postPatch = ''
sed -ie 's|/var/lib/wifish|${placeholder "out"}/var/lib/wifish|' wifish
'';
dontConfigure = true;
installPhase = ''
install -D -m0644 awk/wscanparse.awk ${placeholder "out"}/var/lib/wifish/wscanparse.awk
install -D -m0644 awk/wlistparse.awk ${placeholder "out"}/var/lib/wifish/wlistparse.awk
install -D -m0644 awk/wscan2menu.awk ${placeholder "out"}/var/lib/wifish/wscan2menu.awk
install -D -m0644 awk/iwparse.awk ${placeholder "out"}/var/lib/wifish/iwparse.awk
install -D -m0755 wifish ${placeholder "out"}/bin/wifish
'';
postFixup = ''
wrapProgram ${placeholder "out"}/bin/wifish \
--prefix PATH ":" ${stdenv.lib.makeBinPath [ dialog gawk wpa_supplicant ]}
'';
meta = with stdenv.lib; {
homepage = "https://github.com/bougyman/wifish";
description = "Simple wifi shell script for linux";
license = licenses.wtfpl;
maintainers = with maintainers; [ AndersonTorres ];
platforms = with platforms; linux;
};
}

View File

@ -8292,6 +8292,8 @@ in
whois = callPackage ../tools/networking/whois { };
wifish = callPackage ../tools/networking/wifish { };
wifite2 = callPackage ../tools/networking/wifite2 { };
wimboot = callPackage ../tools/misc/wimboot { };