Unverified Commit 5200ef07 authored by Jörg Thalheim's avatar Jörg Thalheim Committed by GitHub
Browse files

tea: 0.10.1 -> 0.11.0 (#443069)

parents 305826dc caf5ced5
Loading
Loading
Loading
Loading
+18 −15
Original line number Diff line number Diff line
@@ -3,32 +3,22 @@
  buildGoModule,
  fetchFromGitea,
  installShellFiles,
  stdenv,
}:

buildGoModule rec {
  pname = "tea";
  version = "0.10.1";
  version = "0.11.0";

  src = fetchFromGitea {
    domain = "gitea.com";
    owner = "gitea";
    repo = "tea";
    rev = "v${version}";
    sha256 = "sha256-Dhb3y13sxkyE+2BjNj7YcsjiIPgznIVyuzWs0F8LNfU=";
    sha256 = "sha256-jM/TR3bApWv0ci98Vb/0YPjlmLuO91WPY9eMHBInIQI=";
  };

  vendorHash = "sha256-mKCsBPBWs3+61em53cEB0shTLXgUg4TivJRogy1tYXw=";

  meta = with lib; {
    description = "Gitea official CLI client";
    homepage = "https://gitea.com/gitea/tea";
    license = licenses.mit;
    maintainers = with maintainers; [
      j4m3s
      techknowlogick
    ];
    mainProgram = "tea";
  };
  vendorHash = "sha256-Y9YDwfubT+RR1v6BTFD+A8GP2ArQaIIoMJmak+Vcx88=";

  ldflags = [
    "-X code.gitea.io/tea/cmd.Version=${version}"
@@ -36,7 +26,7 @@ buildGoModule rec {

  nativeBuildInputs = [ installShellFiles ];

  postInstall = ''
  postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
    installShellCompletion --cmd tea \
      --bash <($out/bin/tea completion bash) \
      --fish <($out/bin/tea completion fish) \
@@ -44,5 +34,18 @@ buildGoModule rec {

    mkdir $out/share/powershell/ -p
    $out/bin/tea completion pwsh > $out/share/powershell/tea.Completion.ps1

    $out/bin/tea man --out $out/share/man/man1/tea.1
  '';

  meta = with lib; {
    description = "Gitea official CLI client";
    homepage = "https://gitea.com/gitea/tea";
    license = licenses.mit;
    maintainers = with maintainers; [
      j4m3s
      techknowlogick
    ];
    mainProgram = "tea";
  };
}