2021-12-06 16:07:01 +00:00
|
|
|
{ lib, buildGoModule, fetchFromGitHub }:
|
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "aliyun-cli";
|
2022-12-17 10:02:37 +00:00
|
|
|
version = "3.0.140";
|
2021-12-06 16:07:01 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
rev = "v${version}";
|
|
|
|
owner = "aliyun";
|
|
|
|
repo = pname;
|
|
|
|
fetchSubmodules = true;
|
2022-12-17 10:02:37 +00:00
|
|
|
sha256 = "sha256-mkUHYow3UA+lZ7/T18Qao9Ugxh27Mm1AuUDAG3JzUrU=";
|
2021-12-06 16:07:01 +00:00
|
|
|
};
|
2021-12-21 02:18:32 +00:00
|
|
|
|
2022-11-27 09:42:12 +00:00
|
|
|
vendorSha256 = "sha256-aviRsflpS9/o2B7mpYQE7d9ahLclM+jiVz+cJOlegCY=";
|
2021-12-06 16:07:01 +00:00
|
|
|
|
2021-12-21 02:18:32 +00:00
|
|
|
subPackages = [ "main" ];
|
2021-12-06 16:07:01 +00:00
|
|
|
|
2022-03-05 16:20:37 +00:00
|
|
|
ldflags = [ "-s" "-w" "-X github.com/aliyun/aliyun-cli/cli.Version=${version}" ];
|
2021-12-06 16:07:01 +00:00
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
mv $out/bin/main $out/bin/aliyun
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
2021-12-21 02:18:32 +00:00
|
|
|
description = "Tool to manage and use Alibaba Cloud resources through a command line interface";
|
2021-12-06 16:07:01 +00:00
|
|
|
homepage = "https://github.com/aliyun/aliyun-cli";
|
2022-03-05 16:20:37 +00:00
|
|
|
changelog = "https://github.com/aliyun/aliyun-cli/releases/tag/v${version}";
|
2021-12-06 16:07:01 +00:00
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ ornxka ];
|
2022-04-27 09:35:20 +00:00
|
|
|
mainProgram = "aliyun";
|
2021-12-06 16:07:01 +00:00
|
|
|
};
|
|
|
|
}
|