blob: 361cf8252d7aea01d1c086ab3a10794105528860 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
|
{ lib, buildGoModule, fetchFromGitHub, installShellFiles, testers, rhoas }:
buildGoModule rec {
pname = "rhoas";
version = "0.51.9";
src = fetchFromGitHub {
owner = "redhat-developer";
repo = "app-services-cli";
rev = "v${version}";
sha256 = "sha256-KDEKuaLFVptQs+h0NBlPt0z9kBb3FkroG5mfEgFFCxM=";
};
vendorSha256 = null;
ldflags = [
"-s"
"-w"
"-X github.com/redhat-developer/app-services-cli/internal/build.Version=${version}"
];
nativeBuildInputs = [installShellFiles];
# Networking tests fail.
doCheck = false;
postInstall = ''
installShellCompletion --cmd rhoas \
--bash <($out/bin/rhoas completion bash) \
--fish <($out/bin/rhoas completion fish) \
--zsh <($out/bin/rhoas completion zsh)
'';
passthru.tests.version = testers.testVersion {
package = rhoas;
command = "HOME=$TMP rhoas version";
};
meta = with lib; {
description = "Command Line Interface for Red Hat OpenShift Application Services";
license = licenses.asl20;
homepage = "https://github.com/redhat-developer/app-services-cli";
changelog = "https://github.com/redhat-developer/app-services-cli/releases/v${version}";
maintainers = with maintainers; [stehessel];
};
}
|