nixpkgs/pkgs/development/tools/continuous-integration/fly/default.nix

38 lines
1.0 KiB
Nix
Raw Normal View History

{ buildGoModule, fetchFromGitHub, stdenv, lib, writeText }:
buildGoModule rec {
pname = "fly";
2021-01-28 17:59:05 -08:00
version = "6.7.4";
src = fetchFromGitHub {
owner = "concourse";
repo = "concourse";
rev = "v${version}";
2021-01-28 17:59:05 -08:00
sha256 = "sha256-EFcgS+ZrmdrIwHAzwSuQFe7UgeWsTRjm2sDv5COdi/k=";
};
2021-01-18 10:51:55 -08:00
vendorSha256 = "sha256-xeptlcJLj+R1BdC8Rdi3hsJVxdrmvfeTMsrhMNGrXi8=";
doCheck = false;
subPackages = [ "fly" ];
buildFlagsArray = ''
-ldflags=
-X github.com/concourse/concourse.Version=${version}
'';
postInstall = lib.optionalString (stdenv.hostPlatform == stdenv.buildPlatform) ''
mkdir -p $out/share/{bash-completion/completions,zsh/site-functions}
$out/bin/fly completion --shell bash > $out/share/bash-completion/completions/fly
$out/bin/fly completion --shell zsh > $out/share/zsh/site-functions/_fly
'';
meta = with lib; {
description = "A command line interface to Concourse CI";
2020-03-14 10:32:06 -07:00
homepage = "https://concourse-ci.org";
license = licenses.asl20;
maintainers = with maintainers; [ ivanbrennan ];
};
2020-05-15 04:51:31 -07:00
}