2024-07-28 22:46:08 +00:00
|
|
|
{
|
|
|
|
pkgs,
|
|
|
|
lib,
|
|
|
|
fetchzip,
|
|
|
|
}:
|
2024-06-19 18:00:17 +00:00
|
|
|
|
|
|
|
pkgs.stdenv.mkDerivation rec {
|
|
|
|
pname = "languagetool-ngrams";
|
|
|
|
version = "20150817";
|
|
|
|
language = "en";
|
|
|
|
|
2024-07-28 22:46:08 +00:00
|
|
|
src = fetchzip {
|
2024-06-19 18:00:17 +00:00
|
|
|
url = "https://languagetool.org/download/ngram-data/ngrams-${language}-${version}.zip";
|
|
|
|
sha256 = "10e548731d9f58189fc36a553f7f685703be30da0d9bb42d1f7b5bf5f8bb232c";
|
|
|
|
};
|
|
|
|
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
installPhase = ''
|
2024-07-28 22:46:08 +00:00
|
|
|
runHook preInstall
|
|
|
|
|
|
|
|
mv -- * $out/
|
|
|
|
|
|
|
|
runHook postInstall
|
2024-06-19 18:00:17 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://dev.languagetool.org/finding-errors-using-n-gram-data.html";
|
|
|
|
description = "LanguageTool can make use of large n-gram data sets to detect errors with words that are often confused, like their and there.";
|
|
|
|
platforms = platforms.linux;
|
|
|
|
license = licenses.cc-by-sa-40;
|
|
|
|
};
|
|
|
|
}
|