Hi Thomas. Thanks again for the reply.

I still don't understand why the TARGET_FILE argument is optional. I would expect it to create a file of the same name of the org file that is tangled. Take this code:

(org-babel-tangle-file "~/.emacs.d/config/peepopen-config.org")

Contents:

* Load it
#+BEGIN_SRC emacs-lisp
  (add-to-list 'load-path (concat fullofcaffeine-vendor-dir "/peepopen"))
  (require 'peepopen)
  (textmate-mode)
(provide 'peepopenconfig)
#+END_SRC

When I evaluate the (org-babel-tangle-file...) line, I get the following:

Tangled 0 code blocks from peepopen-config.org

I would expect it to tangle 1 block, and create a peepopen-config.el (no need to define a TARGET_FILE string).

Two questions:

1) Not sure why it's not tangling the BEGIN_SRC emacs-lisp block
2) Am I wrong about the .el file creation assumption ?

Cheers!

- Marcelo.

On Mon, Mar 25, 2013 at 5:39 PM, Thomas S. Dye <tsd@tsdye.com> wrote:
Aloha Marcelo,

Marcelo de Moraes Serpa <celoserpa@gmail.com> writes:

> Oh, actually that wasn't the issue.
>
> org-babel-load-file seems to force tangling the file to an .el.
> org-babel-tangle-file doesn't. Is there a way to force the output to the
> .el file without using the parameter in the code block itself?
>

Yes, there is.

(org-babel-tangle-file FILE &optional TARGET-FILE LANG)

You should be able set TARGET-FILE with a buffer-wide header argument,
like this:

#+PROPERTY: tangle force-output-to-the.el

hth,
Tom

--
T.S. Dye & Colleagues, Archaeologists
735 Bishop St, Suite 315, Honolulu, HI 96813
Tel: 808-529-0866, Fax: 808-529-0884
http://www.tsdye.com