emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Bug: org-agenda-file-regexp not used in org.el?
@ 2007-12-26 21:28 Wanrong Lin
  2007-12-29 12:15 ` Bastien
  0 siblings, 1 reply; 3+ messages in thread
From: Wanrong Lin @ 2007-12-26 21:28 UTC (permalink / raw)
  To: emacs-orgmode


Hi,

I am trying to customize the org-agenda-file-regexp variable to exclude 
those auto backup files starting with "#", but found out the regexp does 
not have any effect on agend file list. And I further found out it seems 
the variable org-agenda-file-regexp is not used in org.el at all. In 
function "org-agenda-files", the regular expression is hard coded to 
"\\.org\\'", as in these two lines:

(if (file-directory-p f)
     (directory-files f t "\\.org\\'")

I wonder whether this is a bug and should be fixed. Thank you.

Wanrong

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

* Re: Bug: org-agenda-file-regexp not used in org.el?
  2007-12-26 21:28 Bug: org-agenda-file-regexp not used in org.el? Wanrong Lin
@ 2007-12-29 12:15 ` Bastien
  2008-01-02 22:05   ` Carsten Dominik
  0 siblings, 1 reply; 3+ messages in thread
From: Bastien @ 2007-12-29 12:15 UTC (permalink / raw)
  To: Wanrong Lin; +Cc: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 635 bytes --]

Wanrong Lin <wanrong.lin@gmail.com> writes:

> I am trying to customize the org-agenda-file-regexp variable to exclude
> those auto backup files starting with "#", but found out the regexp does
> not have any effect on agend file list. And I further found out it seems
> the variable org-agenda-file-regexp is not used in org.el at all. In
> function "org-agenda-files", the regular expression is hard coded to
> "\\.org\\'", as in these two lines:
>
> (if (file-directory-p f)
>     (directory-files f t "\\.org\\'")
>
> I wonder whether this is a bug and should be fixed. Thank you.

I think this should be fixed.  Here is a patch.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: org.el.patch --]
[-- Type: text/x-diff, Size: 574 bytes --]

diff -u /home/guerry/elisp/testing/org/ /home/guerry/elisp/testing/bzg/org.el
--- /home/guerry/elisp/testing/org/org.el	2007-12-20 14:38:42.000000000 +0100
+++ /home/guerry/elisp/testing/bzg/org.el	2007-12-29 13:13:03.000000000 +0100
@@ -19618,7 +19618,7 @@
     (setq files (apply 'append
 		       (mapcar (lambda (f)
 				 (if (file-directory-p f)
-				     (directory-files f t "\\.org\\'")
+				     (directory-files f t org-agenda-file-regexp)
 				   (list f)))
 			       files)))
     (if org-agenda-skip-unavailable-files

Diff finished.  Sat Dec 29 13:13:41 2007

[-- Attachment #3: Type: text/plain, Size: 13 bytes --]


-- 
Bastien

[-- Attachment #4: 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] 3+ messages in thread

* Re: Bug: org-agenda-file-regexp not used in org.el?
  2007-12-29 12:15 ` Bastien
@ 2008-01-02 22:05   ` Carsten Dominik
  0 siblings, 0 replies; 3+ messages in thread
From: Carsten Dominik @ 2008-01-02 22:05 UTC (permalink / raw)
  To: Bastien; +Cc: emacs-orgmode

Bummer!

Fixed for next version, of course.  Thanks for report and fix.

- Carsten

On Dec 29, 2007, at 1:15 PM, Bastien wrote:

> Wanrong Lin <wanrong.lin@gmail.com> writes:
>
>> I am trying to customize the org-agenda-file-regexp variable to  
>> exclude
>> those auto backup files starting with "#", but found out the regexp  
>> does
>> not have any effect on agend file list. And I further found out it  
>> seems
>> the variable org-agenda-file-regexp is not used in org.el at all. In
>> function "org-agenda-files", the regular expression is hard coded to
>> "\\.org\\'", as in these two lines:
>>
>> (if (file-directory-p f)
>>    (directory-files f t "\\.org\\'")
>>
>> I wonder whether this is a bug and should be fixed. Thank you.
>
> I think this should be fixed.  Here is a patch.
>
> diff -u /home/guerry/elisp/testing/org/ /home/guerry/elisp/testing/ 
> bzg/org.el
> --- /home/guerry/elisp/testing/org/org.el	2007-12-20  
> 14:38:42.000000000 +0100
> +++ /home/guerry/elisp/testing/bzg/org.el	2007-12-29  
> 13:13:03.000000000 +0100
> @@ -19618,7 +19618,7 @@
>     (setq files (apply 'append
> 		       (mapcar (lambda (f)
> 				 (if (file-directory-p f)
> -				     (directory-files f t "\\.org\\'")
> +				     (directory-files f t org-agenda-file-regexp)
> 				   (list f)))
> 			       files)))
>     (if org-agenda-skip-unavailable-files
>
> Diff finished.  Sat Dec 29 13:13:41 2007
>
> -- 
> Bastien
> _______________________________________________
> 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] 3+ messages in thread

end of thread, other threads:[~2008-01-02 22:05 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-12-26 21:28 Bug: org-agenda-file-regexp not used in org.el? Wanrong Lin
2007-12-29 12:15 ` Bastien
2008-01-02 22:05   ` Carsten Dominik

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