* Re: Emacs-orgmode Digest, Vol 37, Issue 121
[not found] <E1Lnb4u-0006nm-1T@box188.bluehost.com>
@ 2009-03-29 14:48 ` Robert Goldman
2009-03-29 15:39 ` Eraldo Helal
0 siblings, 1 reply; 2+ messages in thread
From: Robert Goldman @ 2009-03-29 14:48 UTC (permalink / raw)
To: emacs-orgmode
From: Matthew Lundin <mdl@imapmail.org>
Subject: Re: [Orgmode] Re: Handling org-file agenda dependenncies?
To: Eraldo Helal <admin@eraldo.at>
Cc: emacs-orgmode@gnu.org
Message-ID: <m2tz5doo8m.fsf@fastmail.fm>
Content-Type: text/plain; charset=us-ascii
ML> Hi Eraldo,
ML> Eraldo Helal <admin@eraldo.at> writes:
>> > Mike Newman <mike <at> newmanfamily.me.uk> writes: >
>>> >> When you use the standard commands to add/removes files from
the >>
>>> agenda, it will write a definition for the variable
org-agenda-files to
>>> >> the custom section of your .emacs file.
>> > > That would still mean removing every org-file in the tree
manually >
>> when wanting to make a project "inactive". >
>>> >> If you want to deal with trees of files, you might be better
off >>
>>> removing the variable from the custom section, defining it >>
yourself
>>> and updating it manually.
>> > > The questions here is... How could one define it?
ML> I think you could set something like the following in your
.emacs file:
ML> --8<---------------cut here---------------start------------->8---
ML> (load-library "find-lisp") (setq org-agenda-files (append
ML> (find-lisp-find-files "~/directory1" "\.org$") (find-lisp-find-files
ML> "~/directory2" "\.org$") (find-lisp-find-files "~/directory3"
ML> "\.org$"))) --8<---------------cut
ML> here---------------end--------------->8---
ML> This will search the directories above recursively for org files.
ML> Whenever you want to remove a project from your agenda, simply
delete
ML> the appropriate line and evaluate the expression. I'd imagine
someone
ML> else can think of a way to do this more economically, though.
An interesting question would be how to generalize this to update
remember templates accordingly. Possibly the best approach would be to
have a defining form that would define a project in a single
s-expression, adding both remember templates and agenda entries, and
then that form could be removed all at once. Something like
(org-add-project newproj
"A sample new project to show the greatness of org-add-project."
(agenda-files (find-lisp-find-files "~/newproj/" "\.org$"))
(remember-templates
....))
[The above wouldn't work as written, since it's syntax is a mess of what
would be handled by a macro --- the "named arguments" like agenda-files
and remember-templates --- and what looks like a functional argument ---
the find-lisp-files --- but something like it could be lashed together
if anyone was interested.]
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Re: Emacs-orgmode Digest, Vol 37, Issue 121
2009-03-29 14:48 ` Emacs-orgmode Digest, Vol 37, Issue 121 Robert Goldman
@ 2009-03-29 15:39 ` Eraldo Helal
0 siblings, 0 replies; 2+ messages in thread
From: Eraldo Helal @ 2009-03-29 15:39 UTC (permalink / raw)
To: Robert Goldman; +Cc: emacs-orgmode
[-- Attachment #1.1: Type: text/plain, Size: 903 bytes --]
>
> An interesting question would be how to generalize this to update
> remember templates accordingly. Possibly the best approach would be to
> have a defining form that would define a project in a single
> s-expression, adding both remember templates and agenda entries, and
> then that form could be removed all at once. Something like
>
> (org-add-project newproj
> "A sample new project to show the greatness of org-add-project."
> (agenda-files (find-lisp-find-files "~/newproj/" "\.org$"))
> (remember-templates
> ....))
>
> [The above wouldn't work as written, since it's syntax is a mess of what
> would be handled by a macro --- the "named arguments" like agenda-files
> and remember-templates --- and what looks like a functional argument ---
> the find-lisp-files --- but something like it could be lashed together
> if anyone was interested.]
>
Sounds great!
I like your idea. :)
[-- Attachment #1.2: Type: text/html, Size: 1213 bytes --]
[-- Attachment #2: Type: text/plain, Size: 204 bytes --]
_______________________________________________
Emacs-orgmode mailing list
Remember: use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-03-29 15:39 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <E1Lnb4u-0006nm-1T@box188.bluehost.com>
2009-03-29 14:48 ` Emacs-orgmode Digest, Vol 37, Issue 121 Robert Goldman
2009-03-29 15:39 ` Eraldo Helal
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).