From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bastien Subject: Re: showing lists in agenda, and writing org-agenda to a file Date: Mon, 07 Jan 2008 03:34:39 +0000 Message-ID: <874pdq1f74.fsf@bzg.ath.cx> References: <878x35i535.fsf@novell.com> <18305.32180.980606.710374@erics-mac.local> <87prwefj7e.fsf@bzg.ath.cx> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JBilF-0000at-Hz for emacs-orgmode@gnu.org; Sun, 06 Jan 2008 22:34:49 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JBilA-0000WR-HZ for emacs-orgmode@gnu.org; Sun, 06 Jan 2008 22:34:48 -0500 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JBilA-0000WD-5g for emacs-orgmode@gnu.org; Sun, 06 Jan 2008 22:34:44 -0500 Received: from fg-out-1718.google.com ([72.14.220.159]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JBil9-0005MP-Ot for emacs-orgmode@gnu.org; Sun, 06 Jan 2008 22:34:43 -0500 Received: by fg-out-1718.google.com with SMTP id d23so4595803fga.30 for ; Sun, 06 Jan 2008 19:34:42 -0800 (PST) In-Reply-To: <87prwefj7e.fsf@bzg.ath.cx> (Bastien's message of "Mon, 07 Jan 2008 02:44:21 +0000") 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: Eric Schulte Cc: emacs-orgmode@gnu.org Bastien writes: > ;; Use (org-write-agenda file) > (defun org-agenda-to-file (key file &optional max-line-width) > "Write the `org-agenda' view associated with KEY to FILE. > MAX-LINE-WIDTH optionally specifies the maximum line width for > the text in the resulting file." > (interactive) > (save-window-excursion > (org-agenda nil key) > (switch-to-buffer "*Org Agenda*") > (org-write-agenda file) > (org-agenda-quit)) > (if max-width (put-file-content-in-procustes-bed > file max-line-length))) Sorry, typos, should read: (defun org-agenda-to-file (key file &optional max-line-width) "Write the `org-agenda' view associated with KEY to FILE. MAX-LINE-WIDTH optionally specifies the maximum line width for the text in the resulting file." (interactive) (save-window-excursion (org-agenda nil key) (switch-to-buffer "*Org Agenda*") (org-write-agenda file) (org-agenda-quit)) (if max-line-width (put-file-content-in-procustes-bed file max-line-width))) -- Bastien