Function: org-agenda-date-prompt
org-agenda-date-prompt is an interactive and byte-compiled function
defined in org-agenda.el.gz.
Signature
(org-agenda-date-prompt ARG)
Documentation
Change the date of this item. Date is prompted for, with default today.
The prefix ARG is passed to the org-time-stamp command and can therefore
be used to request time specification in the time stamp.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/org/org-agenda.el.gz
(defun org-agenda-date-prompt (arg)
"Change the date of this item. Date is prompted for, with default today.
The prefix ARG is passed to the `org-time-stamp' command and can therefore
be used to request time specification in the time stamp."
(interactive "P")
(org-agenda-check-type t 'agenda)
(org-agenda-check-no-diary)
(org-agenda-maybe-loop
#'org-agenda-date-prompt arg t nil
(let* ((marker (or (org-get-at-bol 'org-marker)
(org-agenda-error)))
(buffer (marker-buffer marker))
(pos (marker-position marker)))
(org-with-remote-undo buffer
(with-current-buffer buffer
(widen)
(goto-char pos)
(unless (org-at-timestamp-p 'lax) (error "Cannot find time stamp"))
(org-time-stamp arg (equal (char-after (match-beginning 0)) ?\[)))
(org-agenda-show-new-time marker org-last-changed-timestamp))
(message "Time stamp changed to %s" org-last-changed-timestamp))))