emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* batch printing of diary/agenda without Scheduled items
@ 2007-10-03 10:04 pete phillips
  2007-10-03 15:53 ` Bastien
  0 siblings, 1 reply; 4+ messages in thread
From: pete phillips @ 2007-10-03 10:04 UTC (permalink / raw)
  To: emacs-orgmode

Hi

I want to print out my agenda to share/email to colleagues - entries
from the diary file and normal dates associated with things in angled
brackets eg: <2007-10-01 10:30>

However, I don't want any Scheduled items to appear (as these are not
appointments/dates as such).

I currently use this:

 /usr/bin/emacs-snapshot -batch -l ~/.xemacs/init.el -eval "(setq european-calendar-style nil diary-mail-days 7 diary-file
 \"/home/pete/diary\")"    -eval  '(org-batch-agenda "a"  org-agenda-files (quote ("~/TODO/HOME.org" "~/TODO/SMTL.org")))' 

but it prints the Scheduled dates as well.

What magic incantation do I need to add ? 

Cheers,
Pete

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: batch printing of diary/agenda without Scheduled items
  2007-10-03 10:04 batch printing of diary/agenda without Scheduled items pete phillips
@ 2007-10-03 15:53 ` Bastien
  2007-10-03 16:15   ` Bastien
  0 siblings, 1 reply; 4+ messages in thread
From: Bastien @ 2007-10-03 15:53 UTC (permalink / raw)
  To: emacs-orgmode

pete phillips <pete@smtl.co.uk> writes:

> However, I don't want any Scheduled items to appear (as these are not
> appointments/dates as such).
>
> I currently use this:
>
>  /usr/bin/emacs-snapshot -batch -l ~/.xemacs/init.el -eval "(setq european-calendar-style nil diary-mail-days 7 diary-file
>  \"/home/pete/diary\")"    -eval  '(org-batch-agenda "a"  org-agenda-files (quote ("~/TODO/HOME.org" "~/TODO/SMTL.org")))' 

I think the right way is to add a custom agenda command:

,----
| (org-add-agenda-custom-command
|      '(("X" agenda ""
|        ((org-agenda-skip-function
| 	(lambda() (org-agenda-skip-entry-if 'scheduled 'deadline)))))))
`----

Note that this view also skips deadlines. Then call this new "X" agenda
command like this:

,----
| /usr/bin/emacs-snapshot -batch -l ~/.xemacs/init.el -eval \ "(setq european-calendar-style nil diary-mail-days 7 diary-file
| \"/home/pete/diary\")"    -eval  '(org-batch-agenda "X"  org-agenda-files (quote ("~/TODO/HOME.org" "~/TODO/SMTL.org")))'
`----

-- 
Bastien

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: batch printing of diary/agenda without Scheduled items
  2007-10-03 15:53 ` Bastien
@ 2007-10-03 16:15   ` Bastien
  2007-10-04 15:55     ` pete phillips
  0 siblings, 1 reply; 4+ messages in thread
From: Bastien @ 2007-10-03 16:15 UTC (permalink / raw)
  To: emacs-orgmode

Bastien <bzg@altern.org> writes:

> ,----
> | (org-add-agenda-custom-command
> |      '(("X" agenda ""
> |        ((org-agenda-skip-function
> | 	(lambda() (org-agenda-skip-entry-if 'scheduled 'deadline)))))))
> `----

BTW, I forgot to mention the documentation for this:

  http://orgmode.org/org.html#Special-agenda-views

-- 
Bastien

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: batch printing of diary/agenda without Scheduled items
  2007-10-03 16:15   ` Bastien
@ 2007-10-04 15:55     ` pete phillips
  0 siblings, 0 replies; 4+ messages in thread
From: pete phillips @ 2007-10-04 15:55 UTC (permalink / raw)
  To: Bastien; +Cc: emacs-orgmode


>>>>> "Bastien" == Bastien  <bzg@altern.org> writes:

    >> | (org-add-agenda-custom-command | '(("X" agenda "" |
    >> ((org-agenda-skip-function | (lambda() (org-agenda-skip-entry-if
    >> 'scheduled 'deadline))))))) `----

Excellent. Thanks for that. I now have a custom shell command which cron
can call, and which shows me deadlines but not SCHEULED tasks:

-----------print-agenda.sh-------------------------
#!/bin/sh
# print out agenda without scheduled tasks
# relies on creating a custom command on the fly - "X"
# (thanks to Bastien)
/usr/bin/emacs-snapshot -batch -l ~/.xemacs/init.el \
-eval "(setq european-calendar-style nil diary-mail-days 7 diary-file  \"/home/pete/diary\")" \
-eval  "(org-add-agenda-custom-command '(\"X\" agenda \"\" ((org-agenda-skip-function (lambda() (org-agenda-skip-entry-if 'scheduled))))))" \
-eval  '(org-batch-agenda "X"  org-agenda-files (quote ("~/TODO/HOME.org" "~/TODO/SMTL.org")))'
-----------------------------------------------------

Pete

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2007-10-04 15:55 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-10-03 10:04 batch printing of diary/agenda without Scheduled items pete phillips
2007-10-03 15:53 ` Bastien
2007-10-03 16:15   ` Bastien
2007-10-04 15:55     ` pete phillips

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).