Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at litex 43 lines 1.1 kB view raw
1{ lib 2, buildGoModule 3, fetchFromGitHub 4, installShellFiles 5, qovery-cli 6, testers 7}: 8 9buildGoModule rec { 10 pname = "qovery-cli"; 11 version = "0.59.0"; 12 13 src = fetchFromGitHub { 14 owner = "Qovery"; 15 repo = pname; 16 rev = "v${version}"; 17 hash = "sha256-EPnuCmkJrjj9STO/FlDNYZmyqTAgTHvqxTxmQcgJLmQ="; 18 }; 19 20 vendorHash = "sha256-nW1PZ/cg7rU3e729H9I4Mqi/Q9wbSFMvtl0Urv9Fl8E="; 21 22 nativeBuildInputs = [ installShellFiles ]; 23 24 postInstall = '' 25 installShellCompletion --cmd ${pname} \ 26 --bash <($out/bin/${pname} completion bash) \ 27 --fish <($out/bin/${pname} completion fish) \ 28 --zsh <($out/bin/${pname} completion zsh) 29 ''; 30 31 passthru.tests.version = testers.testVersion { 32 package = qovery-cli; 33 command = "HOME=$(mktemp -d); ${pname} version"; 34 }; 35 36 meta = with lib; { 37 description = "Qovery Command Line Interface"; 38 homepage = "https://github.com/Qovery/qovery-cli"; 39 changelog = "https://github.com/Qovery/qovery-cli/releases/tag/v${version}"; 40 license = with licenses; [ asl20 ]; 41 maintainers = with maintainers; [ fab ]; 42 }; 43}