Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 20.09 39 lines 1.3 kB view raw
1{ stdenv, fetchFromGitHub, buildGoModule }: 2 3buildGoModule rec { 4 pname = "circleci-cli"; 5 version = "0.1.9321"; 6 7 src = fetchFromGitHub { 8 owner = "CircleCI-Public"; 9 repo = pname; 10 rev = "v${version}"; 11 sha256 = "0n0is4aradlx0jbzs819swidi2x1gnpca9f2b0lkxrxgqcm7viix"; 12 }; 13 14 vendorSha256 = "1zd95n9k2fags0qh3wvjinxv1ahygr958mmiax2kz117yipaz4rb"; 15 16 doCheck = false; 17 18 buildFlagsArray = [ "-ldflags=-s -w -X github.com/CircleCI-Public/circleci-cli/version.Version=${version} -X github.com/CircleCI-Public/circleci-cli/version.Commit=${src.rev} -X github.com/CircleCI-Public/circleci-cli/version.packageManager=nix" ]; 19 20 preBuild = '' 21 substituteInPlace data/data.go \ 22 --replace 'packr.New("circleci-cli-box", "../_data")' 'packr.New("circleci-cli-box", "${placeholder "out"}/share/circleci-cli")' 23 ''; 24 25 postInstall = '' 26 install -Dm644 -t $out/share/circleci-cli _data/data.yml 27 ''; 28 29 meta = with stdenv.lib; { 30 # Box blurb edited from the AUR package circleci-cli 31 description = '' 32 Command to enable you to reproduce the CircleCI environment locally and 33 run jobs as if they were running on the hosted CirleCI application. 34 ''; 35 maintainers = with maintainers; [ synthetica ]; 36 license = licenses.mit; 37 homepage = "https://circleci.com/"; 38 }; 39}