ladder.nix
1 { 2 lib, 3 buildGoModule, 4 fetchFromGitHub, 5 }: 6 7 buildGoModule rec { 8 pname = "ladder"; 9 version = "0.0.21"; 10 11 src = fetchFromGitHub { 12 owner = "everywall"; 13 repo = "ladder"; 14 rev = "v${version}"; 15 hash = "sha256-9KL9ghQFyU+8UyPVAfrf/9J24OUDyiUXVXaSqZ8P3/o="; 16 }; 17 18 postPatch = '' 19 echo "v${version}" >handlers/VERSION 20 ''; 21 22 vendorHash = "sha256-LnbmWpKJo7USTcl5RQknw3nGe4YZ7iNWnl/dtT43afk="; 23 24 ldflags = [ 25 "-s" 26 "-w" 27 ]; 28 29 postInstall = '' 30 mv $out/bin/cmd $out/bin/ladder 31 ''; 32 33 meta = with lib; { 34 description = "Alternative to 12ft.io. Bypass paywalls with a proxy ladder and remove CORS headers from any URL"; 35 homepage = "https://github.com/kubero-dev/ladder"; 36 license = licenses.gpl3Only; 37 maintainers = with maintainers; [ jpetrucciani ]; 38 mainProgram = "ladder"; 39 }; 40 }