Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at litex 51 lines 1.0 kB view raw
1{ lib 2, buildGoModule 3, fetchFromGitHub 4, installShellFiles 5, testers 6, shell2http 7}: 8 9buildGoModule rec { 10 pname = "shell2http"; 11 version = "1.16.0"; 12 13 src = fetchFromGitHub { 14 owner = "msoap"; 15 repo = "shell2http"; 16 rev = "v${version}"; 17 hash = "sha256-FHLClAQYCR6DMzHyAo4gjN2nCmMptYevKJbhEZ8AJyE="; 18 }; 19 20 vendorHash = "sha256-K/0ictKvX0sl/5hFDKjTkpGMze0x9fJA98RXNsep+DM="; 21 22 nativeBuildInputs = [ 23 installShellFiles 24 ]; 25 26 ldflags = [ 27 "-s" 28 "-w" 29 "-X=main.version=${version}" 30 ]; 31 32 postInstall = '' 33 installManPage shell2http.1 34 ''; 35 36 passthru.tests = { 37 version = testers.testVersion { 38 package = shell2http; 39 }; 40 }; 41 42 __darwinAllowLocalNetworking = true; 43 44 meta = with lib; { 45 description = "Executing shell commands via HTTP server"; 46 homepage = "https://github.com/msoap/shell2http"; 47 changelog = "https://github.com/msoap/shell2http/releases/tag/${src.rev}"; 48 license = licenses.mit; 49 maintainers = with maintainers; [ figsoda ]; 50 }; 51}