dotfiles/emacs/.emacs.d/config/init-epub.el
Jeremy Dormitzer 1e392aa7a7 Add COF changes
2021-10-15 10:40:32 -04:00

23 lines
579 B
EmacsLisp

;; -*- lexical-binding: t; -*-
(use-package nov
:straight (:host github :repo "wasamasa/nov.el")
:mode (("\\.epub\\'" . nov-mode))
:config
(evil-collection-nov-setup))
(defvar ebook-library
(expand-file-name "~/Sync/Calibre Library")
"Ebook library directory")
(defun find-ebook (book)
"Finds an ebook from my library"
(interactive (list
(completing-read
"Book: "
(directory-files-recursively ebook-library
"\\.epub$"))))
(find-file book))
(provide 'init-epub)