Hello, Thibault Marin <thibault.ma...@gmx.com> writes:
> However, ob-plantuml does not seem to support the prologue option. So I > am modifying my patch to add support for the :prologue and :epilogue > header arguments instead of using a new customization variable. In the > process, I have added support for header variables which are passed to > the PlantUML file via the !define macro. I am also adding a test file > which checks that the temporary file passed to the plantuml program is > properly generated (it does not run or check the output of plantuml). Thank you. > Please let me know you have any comment on the patch. Thanks in > advance. Comments follow. > +(defun org-babel-plantuml-var-to-plantuml (var) > + "Cleanup plantuml variable (remove quotes)." > + (replace-regexp-in-string "\"" "" var)) Since this function is used only once in the code, I suggest to not implement it and use `replace-regexp-in-string' at the appropriate place. > +(defun org-babel-variable-assignments:plantuml (params) > + "Return a list of PlantUML statements assigning the block's variables." Could you document what is PARAMS? > + (mapcar > + (lambda (pair) > + (format "!define %s %s" > + (car pair) > + (org-babel-plantuml-var-to-plantuml (cdr pair)))) > + (org-babel--get-vars params))) > + > +(defun org-babel-plantuml-make-body (body params) > + "Form PlantUML input string." Do you mean "Return PlantUML" input string? Also you need to specify what are body and params. Besides, the same applies to `org-babel-plantuml-var-to-plantuml' above. Is this function really needed, as it is a mere `format'. Regards, -- Nicolas Goaziou