From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ali Tofigh Subject: Re: Listing filtered entries of a journal file with its datestamp Date: Mon, 19 Apr 2010 13:47:20 -0400 Message-ID: References: <451999.37493.qm@web23802.mail.ird.yahoo.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1O3v4X-0008EK-K1 for emacs-orgmode@gnu.org; Mon, 19 Apr 2010 13:47:49 -0400 Received: from [140.186.70.92] (port=50186 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1O3v4R-0008De-Q3 for emacs-orgmode@gnu.org; Mon, 19 Apr 2010 13:47:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1O3v4Q-0007ku-4q for emacs-orgmode@gnu.org; Mon, 19 Apr 2010 13:47:43 -0400 Received: from mail-yx0-f204.google.com ([209.85.210.204]:58171) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1O3v4Q-0007kG-1r for emacs-orgmode@gnu.org; Mon, 19 Apr 2010 13:47:42 -0400 Received: by yxe42 with SMTP id 42so3120897yxe.24 for ; Mon, 19 Apr 2010 10:47:40 -0700 (PDT) In-Reply-To: <451999.37493.qm@web23802.mail.ird.yahoo.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Miguel Ruiz Cc: emacs-orgmode@gnu.org On Fri, Apr 16, 2010 at 12:09, Miguel Ruiz wrote: > I have a simple journal .org file like this: > > ------Begin file--------------- > * <2010-04-16 fri> > Subject 1 > Subject 2 > Subject 1 > Subject 40 > > * <2010-04-17 sat> > Subject 2 > Subject 3 > Subject 1 > Subject 40 > ------End file------------------ > > Every subject is only one line. > > I would like to print the journal but including only the lines with a specific content, determined by a search, like the following > > -----Buffer to print--------- > * <2010-04-16 fri> > Subject 1 > Subject 1 > > * <2010-04-17 sat> > Subject 1 > ------------------------------ > > ------Another buffer to print- > * <2010-04-16 fri> > Subject 40 > > * <2010-04-17 sat> > Subject 40 > ------------------------------ > > I have tried M-x org-occur, but only marks the searched string; I also have tried M-x occur, but generates a list without the dates, and cannot be printed. try using headlines for the lines under your heading and then a sparse tree with a regexp (C-c / /): ------Begin file--------------- * <2010-04-16 fri> ** Subject 1 ** Subject 2 ** Subject 1 ** Subject 40 * <2010-04-17 sat> ** Subject 2 ** Subject 3 ** Subject 1 ** Subject 40 ------End file------------------