From: Ihor Radchenko <yantar92@posteo.net>
To: "Sébastien Gendre" <seb@k-7.ch>
Cc: Org mailing list <emacs-orgmode@gnu.org>
Subject: Re: Link between org-publish project options and org-export-options-alist
Date: Sun, 18 Aug 2024 11:58:44 +0000 [thread overview]
Message-ID: <87h6biyrd7.fsf@localhost> (raw)
In-Reply-To: <87jzgk1p0h.fsf@k-7.ch>
Sébastien Gendre <seb@k-7.ch> writes:
> I (continue to) develop a custom preamble function. And I try to found
> if there is a link between options set in an org-publish project and
> options set in variable `org-export-options-alist.
> ...
> For my function, I have defined one new export option in the variable
> `org-export-options-alist`:
>
> (add-to-list 'org-export-options-alist
> '(:html-doc-name-template "HTML_DOC_NAME_TEMPLATE" my/org-html-doc-name-template nil))
This is a wrong format. Please check the docstring.
Should be '(:html-doc-name-template "HTML_DOC_NAME_TEMPLATE" nil my/org-html-doc-name-template nil)
> But, when I use org-publish and try to retrieve option ":html-doc-name-template" from my
> custom preamble function like this:
>
> …
> (plist-get info :html-doc-name-template)
> …
>
> If I do not define the options `:html-doc-name-temple` in my publish
> project options, I get the value `nil` and not the value of the variable
> `my/org-html-doc-name-template`.
>
> Are the options of org-publish independent of options defined in
> `org-export-options-alist` ?
Publish plist is transferred to INFO plist, taking priority.
However, parsing the in-file keywords and export options should be
configured via export backend (or globally, all backends, as you did by
modifying `org-export-options-alist') - you can create a custom derived
backend programatically within you publishing function via
`org-export-create-backend'.
--
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>
prev parent reply other threads:[~2024-08-18 11:58 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-13 14:22 Link between org-publish project options and org-export-options-alist Sébastien Gendre
2024-08-18 11:58 ` Ihor Radchenko [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87h6biyrd7.fsf@localhost \
--to=yantar92@posteo.net \
--cc=emacs-orgmode@gnu.org \
--cc=seb@k-7.ch \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).