Hello, Arun Isaac <arunis...@systemreboot.net> writes:
> The org mode manual says "The project property list is scoped into this > call as the variable project-plist". But, ox-publish.el has lexical > binding enabled, and the variable project-plist doesn't seem to be > accessible from the executed preparation-function. When I try to access > the variable, I get a (void-variable project-plist) error. > > Please find attached a minimal elisp file to reproduce the bug. > > emacs -Q -l preparation-function-dynamic-scoping.el > > My understanding of dynamic and lexical binding is a little foggy. So, > do let me know if I'm missing something. There are two ways to handle this. 1. Create a new global variable, with appropriate prefix, to hold project plist, e.g., `org-publish-project-plist'; 2. Require preparation functions to accept one parameter, the project plist. I'd favor the second one. In any case, the manual should be updated accordingly. WDYT? Regards, -- Nicolas Goaziou