emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Leandro Henrique Oliveira Fernandes <leandroohf@gmail.com>
To: emacs-orgmode@gnu.org
Subject: How to tangle org file with option comments yes in batch mode
Date: Mon, 10 Aug 2015 11:49:19 -0700	[thread overview]
Message-ID: <CABMtWyUwEuG+XQuPNoa5TRtfmuhGu1gQuHeQEnDncsC-X7tQTA@mail.gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 1749 bytes --]

Hi,

I am trying to tangle a file in batch mode using the script bellow:

emacs.exe  -Q --batch --no-init-file -l init.el --visit file.org -f
org-babel-tangle --kill

== init.el ===

(require 'org)
(require 'org-exp)
(require 'ob)
(require 'ob-tangle)
(require 'ob-R)

(org-babel-do-load-languages
 'org-babel-load-languages
 '((R . t)
   (latex . t)
   (sh . t)
   (plantuml . t)
   (emacs-lisp . t)
   ))

;; For windows
(setq org-babel-R-command
"\"C:/Users/XX/Documents/R/R3.2.0/bin/i386/Rterm.exe --ess --slave
--no-save\"")

== end file ==

And

== file.org ==

-*- mode: org; mode: auto-fill; fill-column: 76 -*-

# Babel settings
#+PROPERTY: session *R*
#+PROPERTY: comments yes
#+PROPERTY: results output
#+PROPERTY: exports none


* Simple babel block

#+name: setup_block
#+begin_src R :tangle Rcode/setup_block.R :exports none :session

  proj.dir <- getwd()
  cat("Proj dir: ", proj.dir,"\n")

#+end_src

== end file ==

When I set #+PROPERTY: comments no, I am able to tangle the file file.org.
However when I set  #+PROPERTY: comments yes I have got this message:

>>>>>>>>
c:/Program\ Files\ \(x86\)/GNU\ Emacs\ 24.3/bin/emacs.exe -Q --batch
--no-init-file -l init.el --visit file.org -f org-babel-tangle --kill
OVERVIEW
Loading vc-svn...
(No changes need to be saved)
No comment syntax is defined.  Use:
<<<<<<

If I just press enter I end up with the error code:

<<<<<<
No comment syntax defined
make: *** [tangle] Error 127
>>>>

The file I want to tangle is a large file with a lot of org-babel blocks. I
understand that the comment is not defined, but I don't know how to set it.

I am running emacs on windows:
GNU Emacs 24.3.1 (i386-mingw-nt6.1.7601)
Org-mode version 8.3.1

Anyone can help me with that?

Thanks,


emacs-or

[-- Attachment #2: Type: text/html, Size: 4006 bytes --]

             reply	other threads:[~2015-08-10 18:49 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-10 18:49 Leandro Henrique Oliveira Fernandes [this message]
  -- strict thread matches above, loose matches on Subject: below --
2015-08-09  5:03 How to tangle org file with option comments yes in batch mode Leandro Henrique Oliveira Fernandes

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CABMtWyUwEuG+XQuPNoa5TRtfmuhGu1gQuHeQEnDncsC-X7tQTA@mail.gmail.com \
    --to=leandroohf@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).