2024-05-28 22:17:20 +08:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildGoModule,
|
|
|
|
fetchFromGitHub,
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "nhost-cli";
|
2025-07-30 13:34:21 +00:00
|
|
|
version = "1.31.1";
|
2024-05-28 22:17:20 +08:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "nhost";
|
|
|
|
repo = "cli";
|
2024-12-07 23:32:43 +08:00
|
|
|
tag = "v${version}";
|
2025-07-30 13:34:21 +00:00
|
|
|
hash = "sha256-UfcQh8jdnNKn5AMerh+J83yuTY/cX20/8UA0NoPBJ14=";
|
2024-05-28 22:17:20 +08:00
|
|
|
};
|
|
|
|
|
|
|
|
vendorHash = null;
|
|
|
|
|
|
|
|
ldflags = [
|
|
|
|
"-s"
|
|
|
|
"-w"
|
|
|
|
"-X=main.Version=v${version}"
|
|
|
|
];
|
|
|
|
|
|
|
|
postInstall = ''
|
2024-06-10 08:05:19 +08:00
|
|
|
mv $out/bin/cli $out/bin/nhost
|
2024-05-28 22:17:20 +08:00
|
|
|
'';
|
|
|
|
|
2024-11-09 09:44:37 +08:00
|
|
|
# require network access
|
2024-10-20 18:05:04 +08:00
|
|
|
checkFlags = [ "-skip=^TestMakeJSONRequest$" ];
|
|
|
|
|
2024-05-28 22:17:20 +08:00
|
|
|
meta = {
|
2024-10-20 18:05:04 +08:00
|
|
|
description = "Tool for setting up a local development environment for Nhost";
|
2024-05-28 22:17:20 +08:00
|
|
|
homepage = "https://github.com/nhost/cli";
|
2024-10-20 18:05:04 +08:00
|
|
|
changelog = "https://github.com/nhost/cli/releases/tag/v${version}";
|
2024-05-28 22:17:20 +08:00
|
|
|
license = lib.licenses.mit;
|
|
|
|
maintainers = with lib.maintainers; [ moraxyc ];
|
|
|
|
mainProgram = "nhost";
|
|
|
|
};
|
|
|
|
}
|