emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Bastien <bzg@altern.org>
To: Eric Schulte <schulte.eric@gmail.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: showing lists in agenda, and writing org-agenda to a file
Date: Mon, 07 Jan 2008 03:34:39 +0000	[thread overview]
Message-ID: <874pdq1f74.fsf@bzg.ath.cx> (raw)
In-Reply-To: <87prwefj7e.fsf@bzg.ath.cx> (Bastien's message of "Mon, 07 Jan 2008 02:44:21 +0000")

Bastien <bzg@altern.org> 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

  reply	other threads:[~2008-01-07  3:34 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-01-04 22:44 org2hpda now on emacswiki Christian Egli
2008-01-07  1:17 ` showing lists in agenda, and writing org-agenda to a file Eric Schulte
2008-01-07  2:44   ` Bastien
2008-01-07  3:34     ` Bastien [this message]
2008-01-12 18:46     ` Eric Schulte

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=874pdq1f74.fsf@bzg.ath.cx \
    --to=bzg@altern.org \
    --cc=emacs-orgmode@gnu.org \
    --cc=schulte.eric@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).