emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [Orgmode] Include files to be used in literate programming


From: Eric Schulte
Subject: Re: [Orgmode] Include files to be used in literate programming
Date: Fri, 17 Sep 2010 08:51:40 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux)

Hi Giorgio,

This is currently not possible as we're not currently expanding
#+include links during tangling.  I agree this would be useful behavior.

This seems to be related to a recent theme on the mailing list of
unifying tangling with the rest of the Org-mode export functionality.
Once/if tangling were treated as an export target, then things like the
expansion of #+include lines would come for free.

Thanks for bringing this up, this will be an important point to keep in
mind while figuring out the future of tangling.

Best -- Eric

Giorgio Valoti <address@hidden> writes:

> Hi all,
> I’ve just switched from OmniFocus and began using Org mode. But I also
> discovered that it can be used for literate programming and I’d like
> to ask if is there a way to use an included file in the tangling
> phase. In other words, I have a file which includes a commons.org
> file, like this:
>
> === commons.org contents ===
> * Variabili comuni
>   :PROPERTIES:
>   :END:
> #+SRCNAME: entity-name
> #+BEGIN_SRC :noweb yes
> nome_tabella
> #+END_SRC
>
>
> === main.org contents ===
> #+INCLUDE: "commons.org"
>
> * Sezione in SQL
>   :PROPERTIES:
>   :END:
> #+SRCNAME: sql-module
> #+BEGIN_SRC sql :tangle module.sql :noweb yes
>   select *
>   from table <<entity-name>>;
> #+END_SRC
>
> <<entity-name>> should come from the commons but it’s not.
>
> Is there a way to expand values from included files?
>
> Thank you in advance.
>
> --
> Giorgio Valoti
>
>
> _______________________________________________
> Emacs-orgmode mailing list
> Please use `Reply All' to send replies to the list.
> address@hidden
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode



reply via email to

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