From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Charles C. Berry" Subject: Re: [PATCH] org-babel-execute-src-block-region Date: Mon, 2 Nov 2015 10:19:12 -0800 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:47829) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZtJhT-00072I-8M for emacs-orgmode@gnu.org; Mon, 02 Nov 2015 13:19:24 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZtJhP-0002NQ-AZ for emacs-orgmode@gnu.org; Mon, 02 Nov 2015 13:19:23 -0500 Received: from iport-acv1-out.ucsd.edu ([132.239.0.176]:19591) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZtJhP-0002NB-1d for emacs-orgmode@gnu.org; Mon, 02 Nov 2015 13:19:19 -0500 In-Reply-To: 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: Carlos Henrique Machado S Esteves Cc: emacs-orgmode@gnu.org On Sun, 1 Nov 2015, Carlos Henrique Machado S Esteves wrote: > Hello, I find it useful to be able to execute only a region of a source > code block, so I've implemented a new function for that. I've tested it > with MATLAB and Python, but it should work for any mode, since it calls > org-babel-execute-src-block. > You might want to check that point and mark are both inside the src block. Otherwise, the results are unpredictable. Also note that: ess-mode, python-mode, sh-mode and octave-mode already provide this capability (and a lot more) for R, python, shell scripts, octave/matlab and some other languages from the edit buffer. `org-babel-demarcate-block' gives the user the ability to break up src blocks into smaller pieces so they can be run independently. Best, Chuck