<commit_before>{ stdenv, lib, fetchgit, pkg-config, git, libmicrohttpd_0_9_70 }:

stdenv.mkDerivation rec {
  pname = "fileshare";
  version = "0.2.4";

  src = fetchgit {
    url = "https://git.tkolb.de/Public/fileshare.git";
    rev = "v${version}";
    sha256 = "03jrhk4vj6bc2w3lsrfjpfflb4laihysgs5i4cv097nr5cz32hyk";
  };

  postPatch = ''
    sed -i 's,$(shell git rev-parse --short HEAD),/${version},g' Makefile
  '';

  nativeBuildInputs = [ pkg-config git ];
  buildInputs = [ libmicrohttpd_0_9_70 ];

  makeFlags = [ "BUILD=release" ];

  installPhase = ''
    mkdir -p $out/bin
    cp bin/release/fileshare $out/bin
  '';

  meta = with lib; {
    description = "A small HTTP Server for quickly sharing files over the network";
    longDescription = "Fileshare is a simple tool for sharing the contents of a directory via a webserver and optionally allowing uploads.";
    homepage = "https://git.tkolb.de/Public/fileshare";
    license = licenses.mit;
    maintainers = [ maintainers.esclear ];
    platforms = platforms.linux;
  };
}
<commit_msg>fileshare: stop using vulnerable libmicrohttpd 0.9.70<commit_after>{ stdenv, lib, fetchgit, pkg-config, git, libmicrohttpd }:

stdenv.mkDerivation rec {
  pname = "fileshare";
  version = "0.2.4";

  src = fetchgit {
    url = "https://git.tkolb.de/Public/fileshare.git";
    rev = "v${version}";
    sha256 = "03jrhk4vj6bc2w3lsrfjpfflb4laihysgs5i4cv097nr5cz32hyk";
  };

  postPatch = ''
    sed -i 's,$(shell git rev-parse --short HEAD),/${version},g' Makefile
  '';

  nativeBuildInputs = [ pkg-config git ];
  buildInputs = [ libmicrohttpd ];

  makeFlags = [ "BUILD=release" ];

  installPhase = ''
    mkdir -p $out/bin
    cp bin/release/fileshare $out/bin
  '';

  meta = with lib; {
    description = "A small HTTP Server for quickly sharing files over the network";
    longDescription = "Fileshare is a simple tool for sharing the contents of a directory via a webserver and optionally allowing uploads.";
    homepage = "https://git.tkolb.de/Public/fileshare";
    license = licenses.mit;
    maintainers = [ maintainers.esclear ];
    platforms = platforms.linux;
  };
}

{'fraction_non_alphanumeric': 0.1311858076563959, 'fraction_numerical': 0.025210084033613446, 'mean_word_length': 3.4460580912863072, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, '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': '7569671', 'n_tokens_mistral': 789, 'n_tokens_neox': 753, 'n_words': 179}