v2ray-rules-dat: init at 202402042209

This commit is contained in:
Guanran Wang 2024-02-05 10:28:43 +08:00
parent 6e2c24bb7a
commit 099fe0b60c
Signed by: nyancat
SSH key fingerprint: SHA256:8oWGKciPALWut/6WA27oFKofX+6Wtc0gQnsefXLQx/8
2 changed files with 37 additions and 0 deletions

View file

@ -3,4 +3,5 @@ pkgs: {
metacubexd = pkgs.callPackage ./metacubexd {}; metacubexd = pkgs.callPackage ./metacubexd {};
mpvScripts.modernx = pkgs.callPackage ./mpvScripts/modernx {}; mpvScripts.modernx = pkgs.callPackage ./mpvScripts/modernx {};
picom-ft-labs = pkgs.callPackage ./picom-ft-labs {}; picom-ft-labs = pkgs.callPackage ./picom-ft-labs {};
v2ray-rules-dat = pkgs.callPackage ./v2ray-rules-dat {};
} }

View file

@ -0,0 +1,36 @@
{
lib,
stdenvNoCC,
fetchurl,
}:
stdenvNoCC.mkDerivation (finalAttrs: {
pname = "v2ray-rules-dat";
version = "202402042209";
srcs = [
(fetchurl {
url = "https://github.com/Loyalsoldier/${finalAttrs.pname}/releases/download/${finalAttrs.version}/geoip.dat";
hash = "sha256-85OXgvpCa7qLzYGaX+YLMDTPBGvZaMpb1INOFnGM1Tw=";
})
(fetchurl {
url = "https://github.com/Loyalsoldier/${finalAttrs.pname}/releases/download/${finalAttrs.version}/geosite.dat";
hash = "sha256-XP9X0l6E9cbvc8AS9yW0mBIyDXfjrV0nxB2tkBHDOFE=";
})
];
dontConfigure = true;
dontBuild = true;
dontUnpack = true;
installPhase = ''
install -Dm644 ${builtins.elemAt finalAttrs.srcs 0} $out/share/v2ray/geoip.dat
install -Dm644 ${builtins.elemAt finalAttrs.srcs 1} $out/share/v2ray/geosite.dat
'';
meta = with lib; {
description = "Enhanced edition of V2Ray rules dat files";
homepage = "https://github.com/Loyalsoldier/v2ray-rules-dat";
license = licenses.gpl3;
platforms = platforms.all;
};
})