emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

ob-clojure :var header argument not work when src block is noweb called


From: stardiviner
Subject: ob-clojure :var header argument not work when src block is noweb called by another src block
Date: Wed, 05 Feb 2020 23:28:27 +0800
User-agent: mu4e 1.3.2; emacs 27.0.50

Here is an example:

#+NAME: read-in-wxid
#+begin_src clojure :var cwd=(file-truename "~/Documents/WeChat/wxid/")
(require '[clojure.java.io :as io])

(def directory (io/file cwd))
(def files (filter #(.isFile %) (file-seq directory)))
#+end_src

#+RESULTS[<2019-08-28 09:12:24> 84a1210d836742ca71ddddc776aaebba0e0224af]: 
read-in-wxid
: #'user/files

#+begin_src clojure :noweb yes :results pp
<<read-in-wxid>>
(take 3 files)
#+end_src

#+RESULTS[<2019-08-28 09:12:30> 9bbcd9f779f72bdd9b7bb8fb85aa36bbdfee7e3c]:
: class clojure.lang.Compiler$CompilerExceptionclass 
clojure.lang.Compiler$CompilerExceptionSyntax error compiling at (*Org Src 
Code.org[ clojure ]*:3:16).
: Unable to resolve symbol: cwd in this context


-- 
[ stardiviner ]
       I try to make every word tell the meaning what I want to express.

       Blog: https://stardiviner.github.io/
       IRC(freenode): stardiviner, Matrix: stardiviner
       GPG: F09F650D7D674819892591401B5DF1C95AE89AC3
      



reply via email to

[Prev in Thread] Current Thread [Next in Thread]