diff options
author | Vasilij Schneidermann <mail@vasilij.de> | 2018-06-17 23:42:43 +0200 |
---|---|---|
committer | Vasilij Schneidermann <mail@vasilij.de> | 2018-06-17 23:42:43 +0200 |
commit | 433232ed1d255e06735c561319abe26bcb4befec (patch) | |
tree | f7a0a5ca91da7aac37df9a219d254ac9da8a74ec | |
parent | b4959103619d94a7a1d5fe1d9a15887fc2b12b8f (diff) |
Use `nov-file-name` to hold original file path
Closes #34
-rw-r--r-- | nov.el | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -99,11 +99,14 @@ If set to `nil', no saving and restoring is performed." (const :tag "Don't save last reading places" nil)) :group 'nov) +(defvar-local nov-file-name nil + "Path to the EPUB file backing this buffer.") + (defvar-local nov-temp-dir nil "Temporary directory containing the buffer's EPUB files.") (defvar-local nov-content-file nil - "Path of the EPUB buffer's .opf file.") + "Path to the EPUB buffer's .opf file.") (defvar-local nov-epub-version nil "Version string of the EPUB buffer.") @@ -686,6 +689,7 @@ Saving is only done if `nov-save-place-file' is set." (apply 'vector))) (setq nov-documents-index 0)) (setq buffer-undo-list t) + (setq nov-file-name (buffer-file-name)) (set-visited-file-name nil t) ; disable autosaves and save questions (let ((place (nov-saved-place (cdr (assq 'identifier nov-metadata))))) (if place |