git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #87885 from flokli/fly-6.1.0

fly: 6.0.0 -> 6.1.0

commitb61158116200270d3ebe323ea1682d1ddd132be9 authorFlorian Klink <flokli@flokli.de> dateFri 15 May 2020, 21:21 (7 years ago) parent59e2e4444c0533
2 files changed+9−21
pkgs/development/tools/continuous-integration/fly/default.nix+9−11 pkgs/development/tools/continuous-integration/fly/fly.bash−10
pkgs/development/tools/continuous-integration/fly/default.nix+9−11
@@ -1,17 +1,17 @@
1−{ buildGoModule, fetchFromGitHub, lib, writeText }:
1+{ buildGoModule, fetchFromGitHub, stdenv, lib, writeText }:
22
33buildGoModule rec {
44 pname = "fly";
5− version = "6.0.0";
5+ version = "6.1.0";
66
77 src = fetchFromGitHub {
88 owner = "concourse";
99 repo = "concourse";
1010 rev = "v${version}";
11− sha256 = "0chavwymyh5kv4fkvdjvf3p5jjx4yn9aavq66333xnsl5pn7q9dq";
11+ sha256 = "14sm3xwhm6pfln18i9f9dyj7s2wcri43rxj4s1cja7nwqr5sqb3x";
1212 };
1313
14− vendorSha256 = "127mc1wzqhn0l4ni6qxcx06qfdb1cgahzypjrs4vgr6i4sipjxck";
14+ vendorSha256 = "1c099sn5rrvj805va1lyjlbv7i2g1z5bxyaisv5l9365z0lv1cwm";
1515
1616 subPackages = [ "fly" ];
1717
@@ -20,12 +20,10 @@ buildGoModule rec {
2020 -X github.com/concourse/concourse.Version=${version}
2121 '';
2222
23− # The fly.bash file included with this derivation can be replaced by a
24− # call to `fly completion bash` once the `completion` subcommand has
25− # made it into a release. Similarly, `fly completion zsh` will provide
26− # zsh completions. https://github.com/concourse/concourse/pull/4012
27− postInstall = ''
28− install -D -m 444 ${./fly.bash} $out/share/bash-completion/completions/fly
23+ postInstall = lib.optionalString (stdenv.hostPlatform == stdenv.buildPlatform) ''
24+ mkdir -p $out/share/{bash-completion/completions,zsh/site-functions}
25+ $out/bin/fly completion --shell bash > $out/share/bash-completion/completions/fly
26+ $out/bin/fly completion --shell zsh > $out/share/zsh/site-functions/_fly
2927 '';
3028
3129 meta = with lib; {
@@ -34,4 +32,4 @@ buildGoModule rec {
3432 license = licenses.asl20;
3533 maintainers = with maintainers; [ ivanbrennan ];
3634 };
37−}
35+}
pkgs/development/tools/continuous-integration/fly/fly.bashdeleted−10
@@ -1,10 +0,0 @@
1−# credits:
2−# https://godoc.org/github.com/jessevdk/go-flags#hdr-Completion
3−# https://github.com/concourse/concourse/issues/1309#issuecomment-452893900
4−_fly_compl() {
5− args=("${COMP_WORDS[@]:1:$COMP_CWORD}")
6− local IFS=$'\n'
7− COMPREPLY=($(GO_FLAGS_COMPLETION=1 ${COMP_WORDS[0]} "${args[@]}"))
8− return 0
9−}
10−complete -F _fly_compl fly