From mboxrd@z Thu Jan 1 00:00:00 1970 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 Message-ID: <874kw55a04.fsf@gmail.com> Reply-To: numbchild@gmail.com Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:53650) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1izMbf-0001lC-Gk for emacs-orgmode@gnu.org; Wed, 05 Feb 2020 10:28:48 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1izMbe-0006IL-1u for emacs-orgmode@gnu.org; Wed, 05 Feb 2020 10:28:47 -0500 Received: from [112.17.238.191] (port=31888 helo=dark.localdomain) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1izMbc-0005Cn-6T for emacs-orgmode@gnu.org; Wed, 05 Feb 2020 10:28:45 -0500 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane-mx.org@gnu.org Sender: "Emacs-orgmode" To: Org Mode 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 <> (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