<commit_before>{ stdenv
, lib
, fetchFromGitHub
, autoconf
, automake
, gettext
, libtool
, perl
, pkg-config
, glib
, xorg
}:
stdenv.mkDerivation rec {
  pname = "xdg-launch";
  version = "1.11";

  postPatch = ''
    # fix gettext configuration
    echo 'AM_GNU_GETTEXT_VERSION' >> configure.ac
    echo 'AM_GNU_GETTEXT([external])' >> configure.ac

    sed -i data/*.desktop \
      -e "s,/usr/bin,/$out/bin,g"
  '';

  src = fetchFromGitHub {
    owner = "bbidulock";
    repo = pname;
    rev = version;
    sha256 = "sha256-qrBxyJ3dUNdnE1nANLKKL0cXw/Hc4qxDoY1anIRN+VA=";
  };

  preConfigure = "./autogen.sh";

  buildInputs = [
    xorg.libX11
    xorg.libXrandr
    glib # can be optional
  ];

  nativeBuildInputs = [
    autoconf
    automake
    gettext
    libtool
    perl # pod2man<commit_msg>xdg-launch: 1.11 -> 1.12<commit_after>{ stdenv
, lib
, fetchFromGitHub
, autoconf
, automake
, gettext
, libtool
, perl
, pkg-config
, glib
, xorg
}:
stdenv.mkDerivation rec {
  pname = "xdg-launch";
  version = "1.12";

  postPatch = ''
    # fix gettext configuration
    echo 'AM_GNU_GETTEXT_VERSION' >> configure.ac
    echo 'AM_GNU_GETTEXT([external])' >> configure.ac

    sed -i data/*.desktop \
      -e "s,/usr/bin,/$out/bin,g"
  '';

  src = fetchFromGitHub {
    owner = "bbidulock";
    repo = pname;
    rev = version;
    sha256 = "sha256-S/0Wn1T5MSOPN6QXkzfmygHL6XTAnnMJr5Z3fBzsHEw=";
  };

  preConfigure = "./autogen.sh";

  buildInputs = [
    xorg.libX11
    xorg.libXrandr
    glib # can be optional
  ];

  nativeBuildInputs = [
    autoconf
    automake
    gettext
    libtool
    perl # pod2man
{'fraction_non_alphanumeric': 0.12984615384615383, 'fraction_numerical': 0.025846153846153845, 'mean_word_length': 2.763888888888889, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 12, 'https://': 0, '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': '5207916', 'n_tokens_mistral': 705, 'n_tokens_neox': 663, 'n_words': 119}