From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Schulte Subject: Re: cleaning all the #+results from an org document Date: Thu, 28 Jul 2011 17:04:57 -0600 Message-ID: <871uxadk3v.fsf@gmail.com> References: <21734.1311841912@maps> <4E3154FA.5000606@gmail.com> <32216.1311857987@maps> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([140.186.70.92]:42247) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qmact-0003Lf-OS for emacs-orgmode@gnu.org; Thu, 28 Jul 2011 20:08:28 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Qmacr-0002Xa-T4 for emacs-orgmode@gnu.org; Thu, 28 Jul 2011 20:08:27 -0400 Received: from mail-pz0-f49.google.com ([209.85.210.49]:61195) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qmacr-0002Wc-Mr for emacs-orgmode@gnu.org; Thu, 28 Jul 2011 20:08:25 -0400 Received: by mail-pz0-f49.google.com with SMTP id 33so4602614pzk.8 for ; Thu, 28 Jul 2011 17:08:25 -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: Ista Zahn Cc: emacs-orgmode@gnu.org, Stephen Eglen Ista Zahn writes: > On Thu, Jul 28, 2011 at 8:59 AM, Stephen Eglen > wrote: >> Thanks Torsten, you've expressed it elegantly! >>> >>> a) send it to someone without the results (to let him create his own) >>> b) archive them without having possible huge amount of lines of >>> results which can be reproduced any time by executing the block again. >>> c) to delete all the old results and start "fresh" > > +1 for c. I often work with R objects that are simply too large to > store in org tables, so I use babel caching + session + write / load R > data files from disk. This works, but it becomes easy to get to an > inconsistent state, and I would like to be able to delete the results > blocks and run the whole thing fresh. > You could try evaluating the following with "M-x :" in an Org-mode buffer. If this works well then I'll give it its own function name and key shortcut (key combo suggestions welcome). #+begin_src emacs-lisp (org-babel-map-src-blocks nil (org-babel-remove-result)) #+end_src Thank -- Eric > > Best, > Ista > >> >> I was mostly thinking about b (for putting into version control) and c, >> for giving to students to try out. >> >> Stephen >> >> -- Eric Schulte http://cs.unm.edu/~eschulte/