blob: fccd2174a6d647e27f74e94fccee7455789ba8fb (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
{ stdenv, fetchzip, jre, makeWrapper }:
stdenv.mkDerivation rec {
pname = "LanguageTool";
version = "4.9.1";
src = fetchzip {
url = "https://www.languagetool.org/download/${pname}-${version}.zip";
sha256 = "0hvzckb92yijzmp2vphjp1wgql3xqq0xd83v5x6pbhziq9yxc5yh";
};
nativeBuildInputs = [ makeWrapper ];
buildInputs = [ jre ];
installPhase = ''
mkdir -p $out/share
mv * $out/share/
for lt in languagetool{,-commandline,-server};do
makeWrapper ${jre}/bin/java $out/bin/$lt \
--add-flags "-cp $out/share/ -jar $out/share/$lt.jar"
done
makeWrapper ${jre}/bin/java $out/bin/languagetool-http-server \
--add-flags "-cp $out/share/languagetool-server.jar org.languagetool.server.HTTPServer"
'';
meta = with stdenv.lib; {
homepage = "https://languagetool.org";
license = licenses.lgpl21Plus;
maintainers = with maintainers; [
edwtjo
];
description = "A proofreading program for English, French German, Polish, and more";
};
}
|