diff options
author | Tobias Happ <tobias.happ@gmx.de> | 2022-11-20 21:06:11 +0100 |
---|---|---|
committer | Rick van Schijndel <Mindavi@users.noreply.github.com> | 2022-12-19 17:36:54 +0100 |
commit | 3ff39f984faa5f528f7ac5e548110d4e20327aa1 (patch) | |
tree | 11867d36d721b2f67e5f7c437ce8dbaf919835bb /pkgs/development/tools/supabase-cli | |
parent | 9bf4ec690947311dd0b080bb8d86a3019d5f4f24 (diff) |
supabase-cli: init at 1.27.0
Diffstat (limited to 'pkgs/development/tools/supabase-cli')
-rw-r--r-- | pkgs/development/tools/supabase-cli/default.nix | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/pkgs/development/tools/supabase-cli/default.nix b/pkgs/development/tools/supabase-cli/default.nix new file mode 100644 index 0000000000000..39ec1d018d37d --- /dev/null +++ b/pkgs/development/tools/supabase-cli/default.nix @@ -0,0 +1,43 @@ +{ lib +, buildGoModule +, fetchFromGitHub +, installShellFiles +}: + +buildGoModule rec { + pname = "supabase-cli"; + version = "1.27.0"; + + src = fetchFromGitHub { + owner = "supabase"; + repo = "cli"; + rev = "v${version}"; + sha256 = "sha256-gAfgqOeJ1cQ5Igxcut0FXkzhK38Q/mUTXfFaZE0dNCs="; + }; + + vendorSha256 = "sha256-RO9dZP236Kt8SSpZFF7KRksrjgwiEkPxE5DIMUK69Kw="; + + ldflags = [ "-s" "-w" "-X" "github.com/supabase/cli/cmd.version=${version}" ]; + + doCheck = false; # tests are trying to connect to localhost + + nativeBuildInputs = [ installShellFiles ]; + + postInstall = '' + rm $out/bin/{codegen,docgen,listdep} + mv $out/bin/{cli,supabase} + + installShellCompletion --cmd supabase \ + --bash <($out/bin/supabase completion bash) \ + --fish <($out/bin/supabase completion fish) \ + --zsh <($out/bin/supabase completion zsh) + ''; + + meta = with lib; { + description = "A CLI for interacting with supabase"; + homepage = "https://github.com/supabase/cli"; + license = licenses.mit; + maintainers = with maintainers; [ gerschtli ]; + mainProgram = "supabase"; + }; +} |