From mboxrd@z Thu Jan 1 00:00:00 1970 From: stardiviner Subject: Re: ob-clojure :var header argument not work when src block is noweb called by another src block Date: Wed, 12 Feb 2020 17:46:35 +0800 Message-ID: <87d0akw31a.fsf@gmail.com> References: <874kw55a04.fsf@gmail.com> Reply-To: numbchild@gmail.com Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:50415) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j1ocH-00012c-U5 for emacs-orgmode@gnu.org; Wed, 12 Feb 2020 04:47:35 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j1ocG-0001eP-MQ for emacs-orgmode@gnu.org; Wed, 12 Feb 2020 04:47:33 -0500 Received: from [112.17.247.90] (port=61805 helo=dark.localdomain) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1j1ocG-0001Tz-6B for emacs-orgmode@gnu.org; Wed, 12 Feb 2020 04:47:32 -0500 In-reply-to: <874kw55a04.fsf@gmail.com> 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: numbchild@gmail.com Cc: emacs-orgmode@gnu.org =2D----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 This problem is missed, Let me resume it. stardiviner writes: > Here is an example: > > #+NAME: read-in-wxid > #+begin_src clojure :var cwd=3D(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.Compile= r$CompilerExceptionSyntax error compiling at (*Org Src Code.org[ clojure ]*= :3:16). > : Unable to resolve symbol: cwd in this context =2D --=20 [ 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 =20=20=20=20=20=20 =2D----BEGIN PGP SIGNATURE----- iQFIBAEBCAAyFiEE8J9lDX1nSBmJJZFAG13xyVromsMFAl5DyaEUHG51bWJjaGls ZEBnbWFpbC5jb20ACgkQG13xyVromsNf7ggAxeVNocyCnuHdy8hhk1xNDJ3EXBay PHquEzImS014tFh2I5yd7OsrtMlbVJ5W9Z4r81ZNsrFtEjYybweiVXsfmGbUjZmN I8AaNqUMQBSWbaSeHrNETX5jTLFJEG86aPsMcvspDBnQtUbfcKl+zveiaC2pvMYh XPzp6xVuQrRDIET6TljQbw9cwlI/8n2q5G/0ts73MdmAlXIKuvcGpgkY9gul7Csy vc1t4wzVXVEllGzEEIK72VegJqi83ACO9n3HTVZqs/hxHmpPjLOI+avi0EiKydi4 G8IHD4FZ6KslkO6epcz4XHAdpuhlN++pvqlmLDldfQUsrBAnEUs9lppbDw=3D=3D =3DvGvD =2D----END PGP SIGNATURE-----