Commit 3ff39f98 authored by Tobias Happ's avatar Tobias Happ Committed by Rick van Schijndel
Browse files

supabase-cli: init at 1.27.0

parent 9bf4ec69
Loading
Loading
Loading
Loading
+43 −0
Original line number Diff line number Diff line
{ 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";
  };
}
+2 −0
Original line number Diff line number Diff line
@@ -18116,6 +18116,8 @@ with pkgs;
  summon = callPackage ../development/tools/summon { };
  supabase-cli = callPackage ../development/tools/supabase-cli { };
  svlint = callPackage ../development/tools/analysis/svlint { };
  svls = callPackage ../development/tools/misc/svls { };