diff options
| author | Chris Wells <chris@mathematicaster.org> | 2024-09-10 14:51:28 -0500 |
|---|---|---|
| committer | Chris Wells <chris@mathematicaster.org> | 2024-09-10 14:51:28 -0500 |
| commit | 4f471484b3a1e16230979a8406503a220b9101f4 (patch) | |
| tree | dc3f5256f275f34d3bcc9573462ed34c7fd97f77 /modules/koreader.nix | |
| parent | 5cb16c34a8c5b803ec723934c1dc828c0e8e3bad (diff) | |
| download | kobo-manager-4f471484b3a1e16230979a8406503a220b9101f4.tar kobo-manager-4f471484b3a1e16230979a8406503a220b9101f4.tar.gz kobo-manager-4f471484b3a1e16230979a8406503a220b9101f4.tar.bz2 kobo-manager-4f471484b3a1e16230979a8406503a220b9101f4.tar.lz kobo-manager-4f471484b3a1e16230979a8406503a220b9101f4.tar.xz kobo-manager-4f471484b3a1e16230979a8406503a220b9101f4.tar.zst kobo-manager-4f471484b3a1e16230979a8406503a220b9101f4.zip | |
I think this is almost working!
Diffstat (limited to 'modules/koreader.nix')
| -rw-r--r-- | modules/koreader.nix | 55 |
1 files changed, 0 insertions, 55 deletions
diff --git a/modules/koreader.nix b/modules/koreader.nix deleted file mode 100644 index 5bcca42..0000000 --- a/modules/koreader.nix +++ /dev/null @@ -1,55 +0,0 @@ -{ config, pkgs, lib, options, ... }: -with builtins // lib; -let - cfg = config.koreader; - importOption = p: (import p { inherit pkgs lib; } cfg.path).option; -in { - options.koreader = { - enable = mkEnableOption "KOReader"; - - path = mkOption { - type = types.str; - default = ".adds/koreader"; - description = "Relative path to KOReader within src"; - }; - - devPath = mkOption { - type = types.str; - default = "/mnt/onboard/${cfg.path}"; - readOnly = true; - internal = true; - }; - - nickelEntry = mkEnableOption "Launch KOReader directly via nickelMenu"; - - file = importOption ./lib/file.nix; - manifest = importOption ./lib/manifest.nix; - - # file = mkOption { - # type = options.file.type; - # default = {}; - # description = "Files relative to ${cfg.path}"; - # }; - }; - - config = mkIf cfg.enable { - # file = mapAttrs' (n: v: { - # name = "koreader-${n}"; - # value = v // { - # target = "${cfg.path}/${v.target}"; - # }; - # }) cfg.file; - - nickel.menu.item = mkIf cfg.nickelEntry { - koreader = singleton { - location = "main"; - label = "KOReader"; - action = "cmd_spawn"; - arg = [ - "quiet" - "exec ${cfg.devPath}/koreader.sh" - ]; - }; - }; - }; -} |
