summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Guerry <bzg@altern.org>2011-02-02 11:04:50 +0100
committerBastien Guerry <bzg@altern.org>2011-02-02 11:04:50 +0100
commit4828e3c2d069be03cd9146297df60ffee5f08520 (patch)
tree869babf30fda4a4b73a87d5512987d7b68720041
parentb6efc82dd0578976db0f93ef10ce0ea3898971f1 (diff)
downloadorg-mode-4828e3c2d069be03cd9146297df60ffee5f08520.tar.gz
Fix bug when using org-schedule/org-deadline on timestamps with complex repeaters.
* org.el (org-schedule, org-deadline): Fix bug: take care of repeating timestamps like ".+1d/3d" or "+1d 10d".
-rw-r--r--lisp/org.el8
1 files changed, 6 insertions, 2 deletions
diff --git a/lisp/org.el b/lisp/org.el
index 0dcc5f4..5051d06 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -11472,7 +11472,9 @@ scheduling will use the corresponding date."
(interactive "P")
(let* ((old-date (org-entry-get nil "DEADLINE"))
(repeater (and old-date
- (string-match "\\([.+]+[0-9]+[dwmy]\\) ?" old-date)
+ (string-match
+ "\\([.+]+[0-9]+[dwmy]\\(?:[/ ][-+]?[0-9]+[dwmy]\\)?\\) ?"
+ old-date)
(match-string 1 old-date))))
(if remove
(progn
@@ -11510,7 +11512,9 @@ scheduling will use the corresponding date."
(interactive "P")
(let* ((old-date (org-entry-get nil "SCHEDULED"))
(repeater (and old-date
- (string-match "\\([.+]+[0-9]+[dwmy]\\) ?" old-date)
+ (string-match
+ "\\([.+]+[0-9]+[dwmy]\\(?:[/ ][-+]?[0-9]+[dwmy]\\)?\\) ?"
+ old-date)
(match-string 1 old-date))))
(if remove
(progn