<commit_before>{ stdenv, buildGoPackage, fetchFromGitHub, git, gnupg, makeWrapper }:

buildGoPackage rec {
  version = "1.6.11";
  name = "gopass-${version}";

  goPackagePath = "github.com/justwatchcom/gopass";

  nativeBuildInputs = [ makeWrapper ];

  src = fetchFromGitHub {
    owner = "justwatchcom";
    repo = "gopass";
    rev = "v${version}";
    sha256 = "12pih414232bsdj1qqc04vck2p9254wjy044n5kbbdqbmfgap7sj";
  };

  wrapperPath = with stdenv.lib; makeBinPath ([
    git
    gnupg
  ]);

  postFixup = ''
    wrapProgram $bin/bin/gopass \
      --prefix PATH : "${wrapperPath}"
  '';

  meta = with stdenv.lib; {
    description     = "The slightly more awesome Standard Unix Password Manager for Teams. Written in Go.";
    homepage        = https://github.com/justwatchcom/gopass;
    license         = licenses.mit;
    maintainers     = with maintainers; [ andir ];
    platforms       = platforms.unix;

    longDescription = ''
      gopass is a rewrite of the pass password manager in Go with the aim of
      making it cross-platform and adding additional features. Our target
      audience are professional developers and sysadmins (and especially teams
      of those) who are well versed with a command line interface. One explicit
      goal for this project is to make it more approachable to non-technical
      users. We go by the UNIX philosophy and try to do one thing and do it
      well, providing a stellar user experience and a sane, simple interface.
    '';
  };
}
<commit_msg>gopass: Install shell completion scripts<commit_after>{ stdenv, buildGoPackage, fetchFromGitHub, git, gnupg, makeWrapper }:

buildGoPackage rec {
  version = "1.6.11";
  name = "gopass-${version}";

  goPackagePath = "github.com/justwatchcom/gopass";

  nativeBuildInputs = [ makeWrapper ];

  src = fetchFromGitHub {
    owner = "justwatchcom";
    repo = "gopass";
    rev = "v${version}";
    sha256 = "12pih414232bsdj1qqc04vck2p9254wjy044n5kbbdqbmfgap7sj";
  };

  wrapperPath = with stdenv.lib; makeBinPath ([
    git
    gnupg
  ]);

  postInstall = ''
    mkdir -p \
      $bin/share/bash-completion/completions \
      $bin/share/zsh/site-functions \
      $bin/share/fish/vendor_completions.d
    $bin/bin/gopass completion bash > $bin/share/bash-completion/completions/_gopass
    $bin/bin/gopass completion zsh  > $bin/share/zsh/site-functions/_gopass
    $bin/bin/gopass completion fish > $bin/share/fish/vendor_completions.d/gopass.fish
  '';

  postFixup = ''
    wrapProgram $bin/bin/gopass \
      --prefix PATH : "${wrapperPath}"
  '';

  meta = with stdenv.lib; {
    description     = "The slightly more awesome Standard Unix Password Manager for Teams. Written in Go.";
    homepage        = https://github.com/justwatchcom/gopass;
    license         = licenses.mit;
    maintainers     = with maintainers; [ andir ];
    platforms       = platforms.unix;

    longDescription = ''
      gopass is a rewrite of the pass password manager in Go with the aim of
      making it cross-platform and adding additional features. Our target
      audience are professional developers and sysadmins (and especially teams
      of those) who are well versed with a command line interface. One explicit
      goal for this project is to make it more approachable to non-technical
      users. We go by the UNIX philosophy and try to do one thing and do it
      well, providing a stellar user experience and a sane, simple interface.
    '';
  };
}

{'fraction_non_alphanumeric': 0.09355210132412205, 'fraction_numerical': 0.016119746689694875, 'mean_word_length': 2.9759725400457664, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 6, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2963138', 'n_tokens_mistral': 1137, 'n_tokens_neox': 1066, 'n_words': 326}