1 /* hyphen dictionaries */
3 { hyphen, stdenv, lib, fetchgit, fetchurl }:
7 libreofficeRepository = "https://anongit.freedesktop.org/git/libreoffice/dictionaries.git";
8 libreofficeCommit = "9e27d044d98e65f89af8c86df722a77be827bdc8";
9 libreofficeSubdir = "de";
11 mkDictFromLibreofficeGit =
12 { subdir, shortName, shortDescription, dictFileName, readmeFileName }:
13 stdenv.mkDerivation rec {
15 pname = "hyphen-dict-${shortName}-libreoffice";
17 url = "https://anongit.freedesktop.org/git/libreoffice/dictionaries.git";
18 rev = "a2bf59878dd76685803ec260e15d875746ad6e25";
19 hash = "sha256-3CvjgNjsrm4obATK6LmtYob8i2ngTbwP6FB4HlJMPCE=";
22 description = "Hyphen dictionary for ${shortDescription} from LibreOffice";
23 homepage = "https://wiki.documentfoundation.org/Development/Dictionaries";
24 license = with licenses; [ mpl20 ];
25 maintainers = with maintainers; [ theCapypara ];
26 platforms = platforms.all;
32 install -dm755 "$out/share/hyphen"
33 install -m644 "hyph_${dictFileName}.dic" "$out/share/hyphen"
35 install -dm755 "$out/share/doc/"
36 install -m644 "README_hyph_${readmeFileName}.txt" "$out/share/doc/${pname}.txt"
47 en-us = stdenv.mkDerivation rec {
48 nativeBuildInputs = hyphen.nativeBuildInputs;
49 version = hyphen.version;
50 pname = "hyphen-dict-en-us";
53 inherit (hyphen.meta) homepage platforms license maintainers;
54 description = "Hyphen dictionary for English (United States)";
66 de-de = mkDictFromLibreofficeGit {
69 shortDescription = "German (Germany)";
70 dictFileName = "de_DE";
71 readmeFileName = "de";
75 de-at = mkDictFromLibreofficeGit {
78 shortDescription = "German (Austria)";
79 dictFileName = "de_AT";
80 readmeFileName = "de";
84 de-ch = mkDictFromLibreofficeGit {
87 shortDescription = "German (Switzerland)";
88 dictFileName = "de_CH";
89 readmeFileName = "de";