diff options
author | Bastien Guerry <bzg@altern.org> | 2011-02-15 06:07:53 +0100 |
---|---|---|
committer | Bastien Guerry <bzg@altern.org> | 2011-02-15 06:07:53 +0100 |
commit | d9eeb15ab9d55316f08cd7efe818119bb7e5fc56 (patch) | |
tree | 43d4acf330a2fe7b1a163f668d79a3f0c57df646 | |
parent | 740afd558daaaa90799fb0f645a27980d03ce018 (diff) | |
download | org-mode-d9eeb15ab9d55316f08cd7efe818119bb7e5fc56.tar.gz |
Fix bug when jumping to a datetree from the agenda.
Datetree entries have a fixed form now:
* 2011
** 2011-02 monthname
*** 2011-02-13 dayname
These headings will not be recognized as datetrees:
* 2011 A task for 2011
** 2011-02 several words
*** 2011-02-13 several words
Thanks to Detlef Steuer for reporting this.
-rw-r--r-- | lisp/org-datetree.el | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lisp/org-datetree.el b/lisp/org-datetree.el index 702b3a9..f0f1b90 100644 --- a/lisp/org-datetree.el +++ b/lisp/org-datetree.el @@ -64,7 +64,7 @@ tree can be found." (goto-char (prog1 (point) (widen)))))) (defun org-datetree-find-year-create (year) - (let ((re "^\\*+[ \t]+\\([12][0-9][0-9][0-9]\\)[ \t]*$") + (let ((re "^\\*+[ \t]+\\([12][0-9][0-9][0-9]\\)$") match) (goto-char (point-min)) (while (and (setq match (re-search-forward re nil t)) @@ -83,7 +83,7 @@ tree can be found." (defun org-datetree-find-month-create (year month) (org-narrow-to-subtree) - (let ((re (format "^\\*+[ \t]+%d-\\([01][0-9]\\)[ \t]*$" year)) + (let ((re (format "^\\*+[ \t]+%d-\\([01][0-9]\\) \\w+$" year)) match) (goto-char (point-min)) (while (and (setq match (re-search-forward re nil t)) @@ -102,7 +102,7 @@ tree can be found." (defun org-datetree-find-day-create (year month day) (org-narrow-to-subtree) - (let ((re (format "^\\*+[ \t]+%d-%02d-\\([0123][0-9]\\)[ \t]*$" year month)) + (let ((re (format "^\\*+[ \t]+%d-%02d-\\([0123][0-9]\\) \\w+$" year month)) match) (goto-char (point-min)) (while (and (setq match (re-search-forward re nil t)) |