From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andreas Leha Subject: Re: Is it possible to run shell script src blocks as root or to export individual blocks? Date: Sat, 03 Mar 2012 17:43:09 +0100 Message-ID: <87ty25hbz6.fsf@med.uni-goettingen.de> References: <87pqctkahb.fsf@gmx.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([208.118.235.92]:53980) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S3s3a-0004of-GN for emacs-orgmode@gnu.org; Sat, 03 Mar 2012 11:43:43 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1S3s3Y-0006b0-LI for emacs-orgmode@gnu.org; Sat, 03 Mar 2012 11:43:41 -0500 Received: from plane.gmane.org ([80.91.229.3]:60936) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S3s3Y-0006as-EC for emacs-orgmode@gnu.org; Sat, 03 Mar 2012 11:43:40 -0500 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1S3s3X-0003rW-2j for emacs-orgmode@gnu.org; Sat, 03 Mar 2012 17:43:39 +0100 Received: from vpn-2120.gwdg.de ([134.76.2.120]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 03 Mar 2012 17:43:39 +0100 Received: from andreas.leha by vpn-2120.gwdg.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 03 Mar 2012 17:43:39 +0100 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 Eric Schulte writes: > Leo Alekseyev writes: > >> I was wondering if there was an easy way to execute some shell >> commands contained in a src block as root. Alternatively, is there a >> quick way to export _just_ that one source block to a temp file so >> that I could run it as root manually? >> > > Just call org-babel-tangle with a prefix argument and it only tangles > the current block > >> Hi, I did not know this either. Thanks for the hint! Shouldn't this be mentioned in the manual (14.4)? I have two questions/issues about this: (1) Can I get noweb-references to be expanded by this? Or how would I tangle one block with noweb references expanded? (2) I am asked for a filename. But the header argument :tangle somefile is overruling my input, which is un-expected. Regards, Andreas