Browse Source

ob-lua: Fix multi-line :var input

* lisp/ob-lua.el (org-babel-lua-var-to-lua): Support multi-line :var
  input using Lua's [=[ ... ]=] syntax instead of the syntactically
  invalid and pythonesque """.

TINYCHANGE
Brad Knotwell 6 months ago
parent
commit
bf9bf7a174
1 changed files with 1 additions and 1 deletions
  1. 1 1
      lisp/ob-lua.el

+ 1 - 1
lisp/ob-lua.el

@@ -148,7 +148,7 @@ specifying a variable of the same value."
     (if (eq var 'hline)
         org-babel-lua-hline-to
       (format
-       (if (and (stringp var) (string-match "[\n\r]" var)) "\"\"%S\"\"" "%S")
+       (if (and (stringp var) (string-match "[\n\r]" var)) "[=[%s]=]" "%S")
        (if (stringp var) (substring-no-properties var) var)))))
 
 (defun org-babel-lua-table-or-string (results)