1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-17 19:21:04 +00:00

Merge pull request #305267 from e1mo/paperless-always-eng

nixos/paperless: Always buidl tesseract with english
This commit is contained in:
Leona Maroni 2024-04-19 12:07:02 +02:00 committed by GitHub
commit 3905a63bdc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 5 additions and 1 deletions

View file

@ -203,9 +203,12 @@ in
apply = pkg: pkg.override {
tesseract5 = pkg.tesseract5.override {
# always enable detection modules
# tesseract fails to build when eng is not present
enableLanguages = if cfg.settings ? PAPERLESS_OCR_LANGUAGE then
[ "equ" "osd" ]
lists.unique (
[ "equ" "osd" "eng" ]
++ lib.splitString "+" cfg.settings.PAPERLESS_OCR_LANGUAGE
)
else null;
};
};

View file

@ -23,6 +23,7 @@ import ./make-test-python.nix ({ lib, ... }: {
};
services.paperless.settings = {
PAPERLESS_DBHOST = "/run/postgresql";
PAPERLESS_OCR_LANGUAGE = "deu";
};
};
}; in self;