emacs-orgmode
[Top][All Lists]
Advanced

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

Re: ob-clojure breaks tangling of comments using org-babel-tangle for cl


From: Anoop GR
Subject: Re: ob-clojure breaks tangling of comments using org-babel-tangle for clojure source code blocks
Date: Tue, 15 Oct 2024 23:21:36 +0530

The contents of the org file were
---
This file contains only two source blocks
#+begin_src clojure :noweb-ref "Define a constant"
(def e 2.72)
;;This is a comment on a line of its own
(def pi 3.14) ;;This is a comment not on a line of its own
#+end_src

The following block will be tangled
#+begin_src clojure :noweb yes :tangle output.clj
<<Define a constant>>
#+end_src
---

On Tue, Oct 15, 2024 at 11:13 PM Anoop GR <anoopemacs@gmail.com> wrote:
Comments in org babel clojure blocks are not tangled out.

Let us take an example org file with the following contents:-

This org file contains only two source blocks and a total of ten lines.
#+begin_src clojure :noweb-ref "Define a constant"
(def e 2.72) 
;;This is a comment on a line of its own
(def pi 3.14) ;;This is a comment not on a line of its own
#+end_src
The following block will be tangled
#+begin_src clojure :noweb yes :tangle ./output.clj
<<Define a constant>>
#+end_src

When I tangle the above file, the contents of the output.clj file are:-
(def e 2.72)

(def pi 3.14) ;;This is a comment not on a line of its own

The comment that was on a line of its own is missing from the tangled output.

Was able to reproduce on both emacs 29.3.50 and 29.4 on Ubuntu 22.04 LTS
Both were started using emacs -Q and then evaluating (require 'ob-clojure) as the only line of config.

reply via email to

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