emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: netty hacky <netty.hacky@gmail.com>
To: Neilen Marais <nmarais@gmail.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: Recursive org-agenda-files
Date: Mon, 3 Oct 2011 10:38:50 -0700	[thread overview]
Message-ID: <CADvi8Rds-xJajsM0QGwp+YGX4wROaVXqxz_AA71wtg+m=-_6Dg@mail.gmail.com> (raw)
In-Reply-To: <CA+TGLxBsufjoYfxUMAih=u0pKchPi1E2YbcG96aji6d90Zn25Q@mail.gmail.com>

Hi Neilen,

I think you want these in your .emacs (from
http://orgmode.org/worg/org-faq.html, "Can I add files recursively to
my list of agenda files?"):
(load-library "find-lisp")
(setq org-agenda-files (find-lisp-find-files "~/org" "\.org$"))

Or you can add each project directory to org-agenda-files yourself,
however, this is not recursive, it only adds .org files under the
project directories, not their sub-directories (see docstring of
org-agenda-files: C-h v org-agenda-files):
(setq org-agenda-files '("~/org/projA" "~/org/projB" "~/org/projC"))

In my setup, I also use the following to exclude directory "exc" from the list:
(eval-when-compile (require 'cl))
(setq org-agenda-files
      (remove-if '(lambda (x)
                    (string-match
                     (concat "^" (regexp-quote (expand-file-name
"~/org/exc/")))
                     x))
                 org-agenda-files))

Net

On Mon, Oct 3, 2011 at 8:48 AM, Neilen Marais <nmarais@gmail.com> wrote:
> Hi,
>
> I like to have a directory per project, with an .org file in each
> directory. Is there a way to set org-agenda-files such that it can
> recursively scan my whole projects dir for all org files?
>
> Thanks
> Neilen
>
>

  reply	other threads:[~2011-10-03 17:38 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-03 15:48 Recursive org-agenda-files Neilen Marais
2011-10-03 17:38 ` netty hacky [this message]
2011-10-04  7:19   ` Neilen Marais
2011-10-04  7:32     ` Jambunathan K
2011-10-04  7:54       ` Jambunathan K
2011-10-04 12:42         ` Neilen Marais
2011-10-04 14:12           ` Nick Dokos
2011-10-05  2:33             ` Matthew Sauer
2011-10-14 18:53               ` Neilen Marais
2011-10-14 18:48             ` Neilen Marais
  -- strict thread matches above, loose matches on Subject: below --
2008-10-31 12:30 Sullivan, Gregory (US SSA)
2008-10-31 14:32 ` mclundin

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='CADvi8Rds-xJajsM0QGwp+YGX4wROaVXqxz_AA71wtg+m=-_6Dg@mail.gmail.com' \
    --to=netty.hacky@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=nmarais@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).