diff options
| author | Anastasios Manganaris <tassos.manganaris@gmail.com> | 2022-05-29 14:15:27 -0400 |
|---|---|---|
| committer | Jakob L. Kreuze <zerodaysfordays@sdf.org> | 2022-06-01 21:35:44 -0400 |
| commit | bd83688c8d78f61e534a57874b41a2d4cd3a42e2 (patch) | |
| tree | 1562283b0d6d9174d82957e79f4867b2510e3474 | |
| parent | 2e5749d908fd097ac6bbdca7165a3c4eb0675a62 (diff) | |
Add option for extra haunt metadata per file
Hello,
Thank you for making ox-haunt.el. I use some extra metadata to control
how my haunt website is organized. I modified ox-haunt to let me add
extra metadata to each file. Like this:
#+haunt_metadata: ((recent . t) (status . "Completed") (purpose . "Make
development with GNU Guix easier."))
Do you consider this a worthwhile feature? Does this change look
alright?
Best,
Tassos Manganaris
| -rw-r--r-- | ox-haunt.el | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/ox-haunt.el b/ox-haunt.el index 2d9f9fd..5d42f98 100644 --- a/ox-haunt.el +++ b/ox-haunt.el @@ -46,6 +46,7 @@ (template . ox-haunt-template)) :options-alist '((:tags "TAGS" nil nil) + (:haunt-metadata "HAUNT_METADATA" nil nil) (:haunt-base-dir "HAUNT_BASE_DIR" nil ox-haunt-base-dir) (:haunt-images-dir "HAUNT_IMAGES_DIR" nil ox-haunt-images-dir))) @@ -148,6 +149,8 @@ INFO is the current state of the export process, as a plist." (insert (format "%s: %s\n" (substring (symbol-name keyword) 1) (ox-haunt--keyword-as-string info keyword))))) + (dolist (p (read (ox-haunt--keyword-as-string info :haunt-metadata))) + (insert (format "%s: %s\n" (car p) (cdr p)))) (buffer-string)) "---\n" ;; Output the article contents. |