Hi Rainer, Rainer M Krug <r.m.k...@gmail.com> writes:
> On 31/08/10 02:06, Eric Schulte wrote: >> Hi Rainer, >> >> The easiest way to do this should be, >> >> --8<---------------cut here---------------start------------->8--- >> ** pulling information from tags :blue: >> >> #+begin_src R :var color=(car (org-get-tags-at (point))) :tangle example.R >> color >> #+end_src > > OK - that looks good. That solves one problem. > > But it is not actually conditional tangling? It is rather the transation > of a tag into a variable - or am I seeing something wrong? > My fault, I misread your original message, something like the following should work. You can use the uppermost elisp code block to change the value of the tangle-tag to whichever tag you wish to be tangled. --8<---------------cut here---------------start------------->8--- ** conditional tangling #+begin_src emacs-lisp :results silent (setq tangle-tag "right") #+end_src *** first subheading :left: #+begin_src R :tangle (and (equal (car (org-get-tags-at (point))) tangle-tag) "yes") "first" #+end_src *** second subheading :right: #+begin_src R :tangle (and (equal (car (org-get-tags-at (point))) tangle-tag) "yes") "second" #+end_src --8<---------------cut here---------------end--------------->8--- Cheers -- Eric _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode