Use latest paperless version
This commit is contained in:
parent
354a373795
commit
4febb87d2a
|
@ -2,6 +2,7 @@
|
||||||
lib,
|
lib,
|
||||||
config,
|
config,
|
||||||
pkgs,
|
pkgs,
|
||||||
|
masterModulesPath,
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
with lib; let
|
with lib; let
|
||||||
|
@ -9,6 +10,14 @@ with lib; let
|
||||||
cfg = config.pub-solar.paperless;
|
cfg = config.pub-solar.paperless;
|
||||||
xdg = config.home-manager.users."${psCfg.user.name}".xdg;
|
xdg = config.home-manager.users."${psCfg.user.name}".xdg;
|
||||||
in {
|
in {
|
||||||
|
imports = [
|
||||||
|
"${masterModulesPath}/services/misc/paperless.nix"
|
||||||
|
];
|
||||||
|
|
||||||
|
disabledModules = [
|
||||||
|
"services/misc/paperless.nix"
|
||||||
|
];
|
||||||
|
|
||||||
options.pub-solar.paperless = {
|
options.pub-solar.paperless = {
|
||||||
enable = mkEnableOption "All you need to go paperless";
|
enable = mkEnableOption "All you need to go paperless";
|
||||||
ocrLanguage = mkOption {
|
ocrLanguage = mkOption {
|
||||||
|
@ -17,14 +26,24 @@ in {
|
||||||
example = "eng+deu";
|
example = "eng+deu";
|
||||||
default = "eng";
|
default = "eng";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
dataDir = mkOption {
|
||||||
|
description = "Directory to save data in";
|
||||||
|
type = types.str;
|
||||||
|
example = "/home/pub_solar/Paperless";
|
||||||
|
default = "/home/${psCfg.user.name}/Paperless";
|
||||||
|
};
|
||||||
|
|
||||||
consumptionDir = mkOption {
|
consumptionDir = mkOption {
|
||||||
description = "Directory to be watched";
|
description = "Directory to be watched";
|
||||||
type = types.str;
|
type = types.str;
|
||||||
example = "/var/lib/paperless/consume";
|
example = "/var/lib/paperless/consume";
|
||||||
default = "/home/${psCfg.user.name}/Documents";
|
default = "/var/lib/paperless/consume";
|
||||||
};
|
};
|
||||||
|
|
||||||
scannerDefaultDevice = mkOption {
|
scannerDefaultDevice = mkOption {
|
||||||
description = '' The scanner device. To find this, use `scanimage -L`.
|
description = ''
|
||||||
|
The scanner device. To find this, use `scanimage -L`.
|
||||||
|
|
||||||
For example, your output might be the following:
|
For example, your output might be the following:
|
||||||
|
|
||||||
|
@ -44,6 +63,7 @@ in {
|
||||||
enable = true;
|
enable = true;
|
||||||
user = psCfg.user.name;
|
user = psCfg.user.name;
|
||||||
consumptionDir = cfg.consumptionDir;
|
consumptionDir = cfg.consumptionDir;
|
||||||
|
dataDir = cfg.dataDir;
|
||||||
address = "paperless.local";
|
address = "paperless.local";
|
||||||
extraConfig = {
|
extraConfig = {
|
||||||
PAPERLESS_OCR_LANGUAGE = cfg.ocrLanguage;
|
PAPERLESS_OCR_LANGUAGE = cfg.ocrLanguage;
|
||||||
|
|
Loading…
Reference in a new issue