From mboxrd@z Thu Jan 1 00:00:00 1970 From: Yann Le Du Subject: Tangle only current code block? Date: Mon, 8 Oct 2012 01:00:05 +0200 Message-ID: Reply-To: yann.ledu.fr@gmail.com Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=bcaec550b36cbbcefb04cb8011f1 Return-path: Received: from eggs.gnu.org ([208.118.235.92]:45920) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TKzph-0007Pv-Jo for emacs-orgmode@gnu.org; Sun, 07 Oct 2012 19:00:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TKzpd-0004c3-Qd for emacs-orgmode@gnu.org; Sun, 07 Oct 2012 19:00:25 -0400 Received: from mail-ob0-f169.google.com ([209.85.214.169]:38793) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TKzpd-0004br-Lw for emacs-orgmode@gnu.org; Sun, 07 Oct 2012 19:00:21 -0400 Received: by mail-ob0-f169.google.com with SMTP id va7so3672059obc.0 for ; Sun, 07 Oct 2012 16:00:20 -0700 (PDT) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org --bcaec550b36cbbcefb04cb8011f1 Content-Type: text/plain; charset=ISO-8859-1 Hi, I have a bunch of code chunks with stuff like <> and headers like :tangle toto.c exporting to different files in noweb style If I use C-c C-v t, it extracts all of those code chunks nicely However, sometimes I would like to put my cursor inside one of those code chunks and then extract only that one, not the others. Is there a simple way ? I narly found a solution, but to make it work nicely I need to put org-babel-tangle inside a macro, but it fails: if I define a macro : C-x ( M-x org-babel-tangle C-x ) C-x e it fails, saying wrong type argument stringp, nul I'm lost. Yann --bcaec550b36cbbcefb04cb8011f1 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi,

I have a bunch of code ch= unks with stuff like <<fun name>> and headers like :tangle toto= .c exporting to different files in noweb style

If I use C-c C-v t, i= t extracts all of those code chunks nicely

However, sometimes I would like to put my cursor inside one of those co= de chunks and then extract only that one, not the others.

Is there a= simple way ?

I narly found a solution, but to make it work nicely I= need to put org-babel-tangle inside a macro, but it fails: if I define a m= acro :

C-x (
M-x org-babel-tangleC-x )
C-x e

it fails, saying wrong type argument stringp, nul
I'm lost.

Yann
--bcaec550b36cbbcefb04cb8011f1--