<commit_before>{ fetchurl, stdenv, emacs }:

stdenv.mkDerivation rec {
  name = "cedet-1.0pre4";

  src = fetchurl {
    url = "mirror://sourceforge/cedet/${name}.tar.gz";
    sha256 = "0r1cvik8drbx4if3a54xla7l31gcqwb44rqqgfqdvwg5wzcd5slv";
  };

  buildInputs = [ emacs ];

  # FIXME: EIEIO tests fail with:
  # eieio-tests.el:474:1:Error: Symbol's value as variable is void: class-typep-var
  # See http://thread.gmane.org/gmane.emacs.eieio/72 .
  doCheck = false;
  checkPhase = ''
    for dir in *
    do
      if [ -f "$dir/Makefile" ] && grep -q "test:" "$dir/Makefile"
      then
        echo "testing \`$dir'..."
        make test -C "$dir"
      fi
    done
  '';

  installPhase = ''
    ensureDir "$out/share/emacs/site-lisp"
    cp -v */*.el */*/*.el */*.elc */*/*.elc "$out/share/emacs/site-lisp"
    chmod a-x "$out/share/emacs/site-lisp/"*

    ensureDir "$out/share/info"
    cp -v */*.info* */*/*.info* "$out/share/info"
  '';

  meta = {
    description = "CEDET, a Collection of Emacs Development Environment Tools";

    longDescription = ''
      CEDET is a collection of tools written with the end goal of
      creating an advanced development environment in Emacs.
<commit_msg>CEDET 1.0pre6.<commit_after>{ fetchurl, stdenv, emacs }:

stdenv.mkDerivation rec {
  name = "cedet-1.0pre6";

  src = fetchurl {
    url = "mirror://sourceforge/cedet/${name}.tar.gz";
    sha256 = "0pvd54rjlba12cxgqibm8v4i8x43r5c239z891lgcbafjvkzpdxb";
  };

  buildInputs = [ emacs ];

  # FIXME: EIEIO tests fail with:
  # eieio-tests.el:521:1:Error: Symbol's value as variable is void: class-typep-var
  # See http://thread.gmane.org/gmane.emacs.eieio/72 .
  doCheck = false;
  checkPhase = ''
    for dir in *
    do
      if [ -f "$dir/Makefile" ] && grep -q "test:" "$dir/Makefile"
      then
        echo "testing \`$dir'..."
        make test -C "$dir"
      fi
    done
  '';

  installPhase = ''
    ensureDir "$out/share/emacs/site-lisp"
    cp -v */*.el */*/*.el */*.elc */*/*.elc "$out/share/emacs/site-lisp"
    chmod a-x "$out/share/emacs/site-lisp/"*

    ensureDir "$out/share/info"
    cp -v */*.info* */*/*.info* "$out/share/info"
  '';

  meta = {
    description = "CEDET, a Collection of Emacs Development Environment Tools";

    longDescription = ''
      CEDET is a collection of tools written with the end goal of
      creating an advanced development environment in Emacs.

{'fraction_non_alphanumeric': 0.15980024968789014, 'fraction_numerical': 0.024136496046608405, 'mean_word_length': 2.6096096096096097, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5932666', 'n_tokens_mistral': 945, 'n_tokens_neox': 909, 'n_words': 211}