Browse Source

Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode

Eric Schulte 14 years ago
parent
commit
60dbabb263
14 changed files with 178 additions and 76 deletions
  1. 4 2
      ORGWEBPAGE/index.org
  2. 43 32
      doc/org.texi
  3. 2 2
      lisp/ob-exp.el
  4. 3 9
      lisp/ob.el
  5. 14 0
      lisp/org-agenda.el
  6. 15 12
      lisp/org-capture.el
  7. 8 3
      lisp/org-gnus.el
  8. 11 1
      lisp/org-mew.el
  9. 14 5
      lisp/org-mhe.el
  10. 24 5
      lisp/org-mobile.el
  11. 10 0
      lisp/org-rmail.el
  12. 10 0
      lisp/org-vm.el
  13. 11 1
      lisp/org-wl.el
  14. 9 4
      lisp/org.el

+ 4 - 2
ORGWEBPAGE/index.org

@@ -117,11 +117,11 @@ a look at our [[http://orgmode.org/worg/org-quotes.php][collected quotes about O
 #+ATTR_HTML: style="float:right;"
 #+ATTR_HTML: style="float:right;"
   [[http://mobileorg.ncogni.to/][http://mobileorg.ncogni.to/images/screenshot-browse.png]]
   [[http://mobileorg.ncogni.to/][http://mobileorg.ncogni.to/images/screenshot-browse.png]]
 
 
+- <2010-09-24 Fri>: FLOSS Weekly [[http://twit.tv/floss136][interview]] with Carsten available
 - <2010-04-06 Tue>: Release 7.01
 - <2010-04-06 Tue>: Release 7.01
 - <2010-06-06 Sun>: iPhone App [[http://mobileorg.ncogni.to/][MobileOrg]] version 1.3 introduces
 - <2010-06-06 Sun>: iPhone App [[http://mobileorg.ncogni.to/][MobileOrg]] version 1.3 introduces
   DropBox support, for vastly easier setup.
   DropBox support, for vastly easier setup.
 - <2010-04-06 Tue>: Release 6.35
 - <2010-04-06 Tue>: Release 6.35
-- <2010-01-10 Sun>: Release 6.34
 
 
 * Current Version (7.01h)
 * Current Version (7.01h)
 
 
@@ -200,7 +200,9 @@ and corresponding to the latest git version.
 
 
 ** Talks about Org-mode
 ** Talks about Org-mode
    Check out the [[file:talks/index.html#sec-1][Google Tech Talk]] about Org-mode, or another talk
    Check out the [[file:talks/index.html#sec-1][Google Tech Talk]] about Org-mode, or another talk
-   given at the [[file:talks/index.html#sec-2][Max Planck Institute for Neurological Research]]
+   given at the [[file:talks/index.html#sec-2][Max Planck Institute for Neurological Research]].  On
+   FLOSS Weekly [[http://twit.tv/floss136][show number 136]] Randal Schwartz interviews Carsten
+   about Org mode.
 ** Mailing list
 ** Mailing list
    :PROPERTIES:
    :PROPERTIES:
    :ID:       0B280B26-A3AB-4E5C-B4EE-B7FFC52C4D26
    :ID:       0B280B26-A3AB-4E5C-B4EE-B7FFC52C4D26

+ 43 - 32
doc/org.texi

@@ -3131,15 +3131,16 @@ letters, numbers, @samp{-}, and @samp{_}.  Abbreviations are resolved
 according to the information in the variable @code{org-link-abbrev-alist}
 according to the information in the variable @code{org-link-abbrev-alist}
 that relates the linkwords to replacement text.  Here is an example:
 that relates the linkwords to replacement text.  Here is an example:
 
 
-@lisp
+@smalllisp
 @group
 @group
 (setq org-link-abbrev-alist
 (setq org-link-abbrev-alist
   '(("bugzilla" . "http://10.1.2.9/bugzilla/show_bug.cgi?id=")
   '(("bugzilla" . "http://10.1.2.9/bugzilla/show_bug.cgi?id=")
     ("google"   . "http://www.google.com/search?q=")
     ("google"   . "http://www.google.com/search?q=")
-    ("ads"      . "http://adsabs.harvard.edu/cgi-bin/
-                   nph-abs_connect?author=%s&db_key=AST")))
+    ("gmap"     . "http://maps.google.com/maps?q=%s")
+    ("omap"     . "http://nominatim.openstreetmap.org/search?q=%s&polygon=1")
+    ("ads"      . "http://adsabs.harvard.edu/cgi-bin/nph-abs_connect?author=%s&db_key=AST")))
 @end group
 @end group
-@end lisp
+@end smalllisp
 
 
 If the replacement text contains the string @samp{%s}, it will be
 If the replacement text contains the string @samp{%s}, it will be
 replaced with the tag.  Otherwise the tag will be appended to the string
 replaced with the tag.  Otherwise the tag will be appended to the string
@@ -3148,8 +3149,11 @@ be called with the tag as the only argument to create the link.
 
 
 With the above setting, you could link to a specific bug with
 With the above setting, you could link to a specific bug with
 @code{[[bugzilla:129]]}, search the web for @samp{OrgMode} with
 @code{[[bugzilla:129]]}, search the web for @samp{OrgMode} with
-@code{[[google:OrgMode]]} and find out what the Org author is
-doing besides Emacs hacking with @code{[[ads:Dominik,C]]}.
+@code{[[google:OrgMode]]}, show the map location of the Free Software
+Foundation @code{[[gmap:51 Franklin Street, Boston]]} or of Carsten office
+@code{[[omap:Science Park 904, Amsterdam, The Netherlands]]} and find out
+what the Org author is doing besides Emacs hacking with
+@code{[[ads:Dominik,C]]}.
 
 
 If you need special abbreviations just for a single Org buffer, you
 If you need special abbreviations just for a single Org buffer, you
 can define them in the file with
 can define them in the file with
@@ -6194,16 +6198,19 @@ similar way.}:
 @smallexample
 @smallexample
 Link type          |  Available keywords
 Link type          |  Available keywords
 -------------------+----------------------------------------------
 -------------------+----------------------------------------------
-bbdb               |  %:name %:company
-bbdb               |  %::server %:port %:nick
-vm, wl, mh, rmail  |  %:type %:subject %:message-id
-                   |  %:from %:fromname %:fromaddress
-                   |  %:to   %:toname   %:toaddress
-                   |  %:fromto @r{(either "to NAME" or "from NAME")@footnote{This will always be the other, not the user.  See the variable @code{org-from-is-user-regexp}.}}
-gnus               |  %:group, @r{for messages also all email fields}
-w3, w3m            |  %:url
-info               |  %:file %:node
-calendar           |  %:date
+bbdb                    |  %:name %:company
+irc                     |  %:server %:port %:nick
+vm, wl, mh, mew, rmail  |  %:type %:subject %:message-id
+                        |  %:from %:fromname %:fromaddress
+                        |  %:to   %:toname   %:toaddress
+                        |  %:date @r{(message date header field)}
+                        |  %:date-timestamp @r{(date as active timestamp)}
+                        |  %:date-timestamp-inactive @r{(date as inactive timestamp)}
+                        |  %:fromto @r{(either "to NAME" or "from NAME")@footnote{This will always be the other, not the user.  See the variable @code{org-from-is-user-regexp}.}}
+gnus                    |  %:group, @r{for messages also all email fields}
+w3, w3m                 |  %:url
+info                    |  %:file %:node
+calendar                |  %:date
 @end smallexample
 @end smallexample
 
 
 @noindent
 @noindent
@@ -14227,13 +14234,15 @@ in-buffer settings, but it will understand the logistics of TODO state
 MobileOrg needs to interact with Emacs through directory on a
 MobileOrg needs to interact with Emacs through directory on a
 server@footnote{If you are using a public server, you might prefer to encrypt
 server@footnote{If you are using a public server, you might prefer to encrypt
 the files on the server.  This can be done with Org-mode 6.35 and, hopefully,
 the files on the server.  This can be done with Org-mode 6.35 and, hopefully,
-with MobileOrg 1.4 (please check before trying to use this).  On the Emacs
-side, configure the variables @code{org-mobile-use-encryption} and
-@code{org-mobile-encryption-password}.}.  The easiest way to create that
-directory is to use a free @uref{http://dropbox.com,Dropbox.com}
-account@footnote{If you cannot use Dropbox, or if your version of MobileOrg
-does not support it, you can use a webdav server.  For more information,
-check out the the documentation of MobileOrg and also this
+with MobileOrg 1.5 (please check before trying to use this).  On the Emacs
+side, configure the variable @code{org-mobile-use-encryption}.  If you can
+safely store the password in your Emacs setup, you might also want to
+configure @code{org-mobile-encryption-password}.  Please read the docstring
+of that variable.}.  The easiest way to create that directory is to use a
+free @uref{http://dropbox.com,Dropbox.com} account@footnote{If you cannot use
+Dropbox, or if your version of MobileOrg does not support it, you can use a
+webdav server.  For more information, check out the the documentation of
+MobileOrg and also this
 @uref{http://orgmode.org/worg/org-faq.php#mobileorg_webdav, FAQ entry}.}.
 @uref{http://orgmode.org/worg/org-faq.php#mobileorg_webdav, FAQ entry}.}.
 When MobileOrg first connects to your Dropbox, it will create a directory
 When MobileOrg first connects to your Dropbox, it will create a directory
 @i{MobileOrg} inside the Dropbox.  After the directory has been created, tell
 @i{MobileOrg} inside the Dropbox.  After the directory has been created, tell
@@ -14256,15 +14265,17 @@ can be included by customizing @code{org-mobiles-files}.  File names will be
 staged with path relative to @code{org-directory}, so all files should be
 staged with path relative to @code{org-directory}, so all files should be
 inside this directory.  The push operation also creates a special Org file
 inside this directory.  The push operation also creates a special Org file
 @file{agendas.org} with all custom agenda view defined by the
 @file{agendas.org} with all custom agenda view defined by the
-user@footnote{While creating the agendas, Org-mode will force (see the
-variable @code{org-mobile-force-id-on-agenda-items}) ID properties on all
-referenced entries, so that these entries can be uniquely
-identified if @i{MobileOrg} flags them for further action.}.  Finally, Org
-writes the file @file{index.org}, containing links to all other files.
-@i{MobileOrg} first reads this file from the server, and then downloads all
-agendas and Org files listed in it.  To speed up the download, MobileOrg will
-only read files whose checksums@footnote{stored automatically in the file
-@file{checksums.dat}} have changed.
+user@footnote{While creating the agendas, Org-mode will force ID properties
+on all referenced entries, so that these entries can be uniquely identified
+if @i{MobileOrg} flags them for further action.  If you do not want to get
+these properties in so many entries, you can set the variable
+@code{org-mobile-force-id-on-agenda-items} to @code{nil}.  Org mode will then
+rely on outline paths, in the hope that these will be unique enough.}.
+Finally, Org writes the file @file{index.org}, containing links to all other
+files.  @i{MobileOrg} first reads this file from the server, and then
+downloads all agendas and Org files listed in it.  To speed up the download,
+MobileOrg will only read files whose checksums@footnote{stored automatically
+in the file @file{checksums.dat}} have changed.
 
 
 @node Pulling from MobileOrg,  , Pushing to MobileOrg, MobileOrg
 @node Pulling from MobileOrg,  , Pushing to MobileOrg, MobileOrg
 @section Pulling from MobileOrg
 @section Pulling from MobileOrg

+ 2 - 2
lisp/ob-exp.el

@@ -49,7 +49,7 @@
 
 
 (defcustom org-export-babel-evaluate t
 (defcustom org-export-babel-evaluate t
   "Switch controlling code evaluation during export.
   "Switch controlling code evaluation during export.
-When set to nil no code will be exported as part of the export
+When set to nil no code will be evaluated as part of the export
 process."
 process."
   :group 'org-babel
   :group 'org-babel
   :type 'boolean)
   :type 'boolean)
@@ -236,7 +236,7 @@ The function respects the value of the :exports header argument."
 (defvar backend)
 (defvar backend)
 (defun org-babel-exp-code (info type)
 (defun org-babel-exp-code (info type)
   "Prepare and return code in the current code block for export.
   "Prepare and return code in the current code block for export.
-Code is prepared in a manner suitable for exportat by
+Code is prepared in a manner suitable for export by
 org-mode.  This function is called by `org-babel-exp-do-export'.
 org-mode.  This function is called by `org-babel-exp-do-export'.
 The code block is not evaluated."
 The code block is not evaluated."
   (let ((lang (nth 0 info))
   (let ((lang (nth 0 info))

+ 3 - 9
lisp/ob.el

@@ -570,15 +570,9 @@ results already exist."
 Call `org-babel-execute-src-block' on every source block in
 Call `org-babel-execute-src-block' on every source block in
 the current buffer."
 the current buffer."
   (interactive "P")
   (interactive "P")
-  (save-excursion
-    (org-save-outline-visibility t
-      (goto-char (point-min))
-      (show-all)
-      (while (re-search-forward org-babel-src-block-regexp nil t)
-	(let ((pos-end (match-end 0)))
-	  (goto-char (match-beginning 0))
-	  (org-babel-execute-src-block arg)
-	  (goto-char pos-end))))))
+  (org-save-outline-visibility t
+    (org-babel-map-src-blocks nil
+      (org-babel-execute-src-block arg))))
 
 
 ;;;###autoload
 ;;;###autoload
 (defun org-babel-execute-subtree (&optional arg)
 (defun org-babel-execute-subtree (&optional arg)

+ 14 - 0
lisp/org-agenda.el

@@ -3556,6 +3556,20 @@ in `org-agenda-text-search-extra-files'."
 	    (member (string-to-char words) '(?- ?+ ?\{)))
 	    (member (string-to-char words) '(?- ?+ ?\{)))
 	(setq boolean t))
 	(setq boolean t))
     (setq words (org-split-string words))
     (setq words (org-split-string words))
+    (let (www w)
+      (while (setq w (pop words))
+	(while (and (string-match "\\\\\\'" w) words)
+	  (setq w (concat (substring w 0 -1) " " (pop words))))
+	(push w www))
+      (setq words (nreverse www) www nil)
+      (while (setq w (pop words))
+	(when (and (string-match "\\`[-+]?{" w)
+		   (not (string-match "}\\'" w)))
+	  (while (and words (not (string-match "}\\'" (car words))))
+	    (setq w (concat w " " (pop words))))
+	  (setq w (concat w " " (pop words))))
+	(push w www))
+      (setq words (nreverse www)))
     (setq org-agenda-last-search-view-search-was-boolean boolean)
     (setq org-agenda-last-search-view-search-was-boolean boolean)
     (when boolean
     (when boolean
       (let (wds w)
       (let (wds w)

+ 15 - 12
lisp/org-capture.el

@@ -224,18 +224,20 @@ or gnus will record the author and the subject of the message, which you
 can access with \"%:from\" and \"%:subject\", respectively.  Here is a
 can access with \"%:from\" and \"%:subject\", respectively.  Here is a
 complete list of what is recorded for each link type.
 complete list of what is recorded for each link type.
 
 
-Link type          |  Available information
--------------------+------------------------------------------------------
-bbdb               |  %:type %:name %:company
-vm, wl, mh, rmail  |  %:type %:subject %:message-id
-                   |  %:from %:fromname %:fromaddress
-                   |  %:to   %:toname   %:toaddress
-                   |  %:fromto (either \"to NAME\" or \"from NAME\")
-gnus               |  %:group, for messages also all email fields and
-                   |  %:org-date (the Date: header in Org format)
-w3, w3m            |  %:type %:url
-info               |  %:type %:file %:node
-calendar           |  %:type %:date"
+Link type               |  Available information
+------------------------+------------------------------------------------------
+bbdb                    |  %:type %:name %:company
+vm, wl, mh, mew, rmail  |  %:type %:subject %:message-id
+                        |  %:from %:fromname %:fromaddress
+                        |  %:to   %:toname   %:toaddress
+                        |  %:fromto (either \"to NAME\" or \"from NAME\")
+                        |  %:date
+                        |  %:date-timestamp (as active timestamp)
+                        |  %:date-timestamp-inactive (as inactive timestamp)
+gnus                    |  %:group, for messages also all email fields
+w3, w3m                 |  %:type %:url
+info                    |  %:type %:file %:node
+calendar                |  %:type %:date"
   :group 'org-capture
   :group 'org-capture
   :type
   :type
   '(repeat
   '(repeat
@@ -679,6 +681,7 @@ already gone."
   (delete-other-windows)
   (delete-other-windows)
   (org-switch-to-buffer-other-window
   (org-switch-to-buffer-other-window
    (org-capture-get-indirect-buffer (org-capture-get :buffer) "CAPTURE"))
    (org-capture-get-indirect-buffer (org-capture-get :buffer) "CAPTURE"))
+  (widen)
   (show-all)
   (show-all)
   (goto-char (org-capture-get :pos))
   (goto-char (org-capture-get :pos))
   (org-set-local 'org-capture-target-marker
   (org-set-local 'org-capture-target-marker

+ 8 - 3
lisp/org-gnus.el

@@ -152,8 +152,11 @@ If `org-store-link' was called with a prefix arg the meaning of
 	   (from (mail-header-from header))
 	   (from (mail-header-from header))
 	   (message-id (org-remove-angle-brackets (mail-header-id header)))
 	   (message-id (org-remove-angle-brackets (mail-header-id header)))
 	   (date (mail-header-date header))
 	   (date (mail-header-date header))
-	   (org-date (format-time-string 
-		      (cdr org-time-stamp-formats) (date-to-time date)))
+	   (date-ts (and date (format-time-string
+			       (org-time-stamp-format t) (date-to-time date))))
+	   (date-ts-ia (and date (format-time-string
+				  (org-time-stamp-format t t)
+				  (date-to-time date))))
 	   (subject (copy-sequence (mail-header-subject header)))
 	   (subject (copy-sequence (mail-header-subject header)))
 	   (to (cdr (assq 'To (mail-header-extra header))))
 	   (to (cdr (assq 'To (mail-header-extra header))))
 	   newsgroups x-no-archive desc link)
 	   newsgroups x-no-archive desc link)
@@ -170,8 +173,10 @@ If `org-store-link' was called with a prefix arg the meaning of
 	      newsgroups (gnus-fetch-original-field "Newsgroups")
 	      newsgroups (gnus-fetch-original-field "Newsgroups")
 	      x-no-archive (gnus-fetch-original-field "x-no-archive")))
 	      x-no-archive (gnus-fetch-original-field "x-no-archive")))
       (org-store-link-props :type "gnus" :from from :subject subject 
       (org-store-link-props :type "gnus" :from from :subject subject 
-			    :date date :org-date org-date
 			    :message-id message-id :group group :to to)
 			    :message-id message-id :group group :to to)
+      (when date
+	(org-add-link-props :date date :date-timestamp date-ts
+			    :date-timestamp-inactive date-ts-ia))
       (setq desc (org-email-link-description)
       (setq desc (org-email-link-description)
 	    link (org-gnus-article-link
 	    link (org-gnus-article-link
 		  group	newsgroups message-id x-no-archive))
 		  group	newsgroups message-id x-no-archive))

+ 11 - 1
lisp/org-mew.el

@@ -81,7 +81,7 @@
 		(mew-case-folder (mew-sinfo-get-case)
 		(mew-case-folder (mew-sinfo-get-case)
 				 (nth 1 (mew-refile-get msgnum)))
 				 (nth 1 (mew-refile-get msgnum)))
 	      (mew-summary-folder-name)))
 	      (mew-summary-folder-name)))
-	   message-id from to subject desc link)
+	   message-id from to subject desc link date date-ts date-ts-ia)
       (save-window-excursion
       (save-window-excursion
 	(if (fboundp 'mew-summary-set-message-buffer)
 	(if (fboundp 'mew-summary-set-message-buffer)
 	    (mew-summary-set-message-buffer folder-name msgnum)
 	    (mew-summary-set-message-buffer folder-name msgnum)
@@ -89,9 +89,19 @@
 	(setq message-id (mew-header-get-value "Message-Id:"))
 	(setq message-id (mew-header-get-value "Message-Id:"))
 	(setq from (mew-header-get-value "From:"))
 	(setq from (mew-header-get-value "From:"))
 	(setq to (mew-header-get-value "To:"))
 	(setq to (mew-header-get-value "To:"))
+	(setq date (mew-header-get-value "Date:"))
+	(setq date-ts (and date (format-time-string
+				 (org-time-stamp-format t)
+				 (date-to-time date))))
+	(setq date-ts-ia (and date (format-time-string
+				    (org-time-stamp-format t t)
+				    (date-to-time date))))
 	(setq subject (mew-header-get-value "Subject:")))
 	(setq subject (mew-header-get-value "Subject:")))
       (org-store-link-props :type "mew" :from from :to to
       (org-store-link-props :type "mew" :from from :to to
 			    :subject subject :message-id message-id)
 			    :subject subject :message-id message-id)
+      (when date
+	(org-add-link-props :date date :date-timestamp date-ts
+			    :date-timestamp-inactive date-ts-ia))
       (setq message-id (org-remove-angle-brackets message-id))
       (setq message-id (org-remove-angle-brackets message-id))
       (setq desc (org-email-link-description))
       (setq desc (org-email-link-description))
       (setq link (org-make-link "mew:" folder-name
       (setq link (org-make-link "mew:" folder-name

+ 14 - 5
lisp/org-mhe.el

@@ -83,13 +83,22 @@ supported by MH-E."
   "Store a link to an MH-E folder or message."
   "Store a link to an MH-E folder or message."
   (when (or (equal major-mode 'mh-folder-mode)
   (when (or (equal major-mode 'mh-folder-mode)
 	    (equal major-mode 'mh-show-mode))
 	    (equal major-mode 'mh-show-mode))
-    (let ((from (org-mhe-get-header "From:"))
-	  (to (org-mhe-get-header "To:"))
-	  (message-id (org-mhe-get-header "Message-Id:"))
-	  (subject (org-mhe-get-header "Subject:"))
-	  link desc)
+    (let* ((from (org-mhe-get-header "From:"))
+	   (to (org-mhe-get-header "To:"))
+	   (message-id (org-mhe-get-header "Message-Id:"))
+	   (subject (org-mhe-get-header "Subject:"))
+	   (date (org-mhe-get-header "Date:"))
+	   (date-ts (and date (format-time-string
+			       (org-time-stamp-format t) (date-to-time date))))
+	   (date-ts-ia (and date (format-time-string
+				  (org-time-stamp-format t t)
+				  (date-to-time date))))
+	   link desc)
       (org-store-link-props :type "mh" :from from :to to
       (org-store-link-props :type "mh" :from from :to to
 			    :subject subject :message-id message-id)
 			    :subject subject :message-id message-id)
+      (when date
+	(org-add-link-props :date date :date-timestamp date-ts
+			    :date-timestamp-inactive date-ts-ia))
       (setq desc (org-email-link-description))
       (setq desc (org-email-link-description))
       (setq link (org-make-link "mhe:" (org-mhe-get-message-real-folder) "#"
       (setq link (org-make-link "mhe:" (org-mhe-get-message-real-folder) "#"
 				(org-remove-angle-brackets message-id)))
 				(org-remove-angle-brackets message-id)))

+ 24 - 5
lisp/org-mobile.el

@@ -90,12 +90,29 @@ You might want to put this file into a directory where only you have access."
 This is a single password which is used for AES-256 encryption.  The same
 This is a single password which is used for AES-256 encryption.  The same
 password must also be set in the MobileOrg application.  All Org files,
 password must also be set in the MobileOrg application.  All Org files,
 including mobileorg.org will be encrypted using this password.
 including mobileorg.org will be encrypted using this password.
+
+SECURITY CONSIDERATIONS:
+
 Note that, when Org runs the encryption commands, the password could
 Note that, when Org runs the encryption commands, the password could
-be visible on your system with the `ps' command.  So this method is only
-intended to keep the files secure on the server, not on your own machine."
+be visible briefly on your system with the `ps' command.  So this method is
+only intended to keep the files secure on the server, not on your own machine.
+
+Also, if you set this variable in an init file (.emacs or .emacs.d/init.el
+or custom.el...) and if that file is stored in a way so that other can read
+it, this also limits the security of this approach.  You can also leave
+this variable empty - Org will then ask for the password once per Emacs
+session."
   :group 'org-mobile
   :group 'org-mobile
   :type '(string :tag "Password"))
   :type '(string :tag "Password"))
 
 
+(defvar org-mobile-encryption-password-session nil)
+
+(defun org-mobile-encryption-password ()
+  (or (org-string-nw-p org-mobile-encryption-password)
+      (org-string-nw-p org-mobile-encryption-password-session)
+      (setq org-mobile-encryption-password-session
+	    (read-passwd "Password for MobileOrg: " t))))
+
 (defcustom org-mobile-inbox-for-pull "~/org/from-mobile.org"
 (defcustom org-mobile-inbox-for-pull "~/org/from-mobile.org"
   "The file where captured notes and flags will be appended to.
   "The file where captured notes and flags will be appended to.
 During the execution of `org-mobile-pull', the file
 During the execution of `org-mobile-pull', the file
@@ -356,7 +373,7 @@ agenda view showing the flagged items."
 	       (string-match "\\S-" org-mobile-checksum-binary))
 	       (string-match "\\S-" org-mobile-checksum-binary))
     (error "No executable found to compute checksums"))
     (error "No executable found to compute checksums"))
   (when org-mobile-use-encryption
   (when org-mobile-use-encryption
-    (unless (string-match "\\S-" org-mobile-encryption-password)
+    (unless (string-match "\\S-" (org-mobile-encryption-password))
       (error
       (error
        "To use encryption, you must set `org-mobile-encryption-password'"))
        "To use encryption, you must set `org-mobile-encryption-password'"))
     (unless (file-writable-p org-mobile-encryption-tempfile)
     (unless (file-writable-p org-mobile-encryption-tempfile)
@@ -649,7 +666,8 @@ encryption program does not understand them."
   "Encrypt INFILE to OUTFILE, using `org-mobile-encryption-password'."
   "Encrypt INFILE to OUTFILE, using `org-mobile-encryption-password'."
   (shell-command
   (shell-command
    (format "openssl enc -aes-256-cbc -salt -pass %s -in %s -out %s"
    (format "openssl enc -aes-256-cbc -salt -pass %s -in %s -out %s"
-	   (shell-quote-argument (concat "pass:" org-mobile-encryption-password))
+	   (shell-quote-argument (concat "pass:"
+					 (org-mobile-encryption-password)))
 	   (shell-quote-argument (expand-file-name infile))
 	   (shell-quote-argument (expand-file-name infile))
 	   (shell-quote-argument (expand-file-name outfile)))))
 	   (shell-quote-argument (expand-file-name outfile)))))
 
 
@@ -657,7 +675,8 @@ encryption program does not understand them."
   "Decrypt INFILE to OUTFILE, using `org-mobile-encryption-password'."
   "Decrypt INFILE to OUTFILE, using `org-mobile-encryption-password'."
   (shell-command
   (shell-command
    (format "openssl enc -d -aes-256-cbc -salt -pass %s -in %s -out %s"
    (format "openssl enc -d -aes-256-cbc -salt -pass %s -in %s -out %s"
-	   (shell-quote-argument (concat "pass:" org-mobile-encryption-password))
+	   (shell-quote-argument (concat "pass:"
+					 (org-mobile-encryption-password)))
 	   (shell-quote-argument (expand-file-name infile))
 	   (shell-quote-argument (expand-file-name infile))
 	   (shell-quote-argument (expand-file-name outfile)))))
 	   (shell-quote-argument (expand-file-name outfile)))))
 
 

+ 10 - 0
lisp/org-rmail.el

@@ -59,10 +59,20 @@
 	       (from (mail-fetch-field "from"))
 	       (from (mail-fetch-field "from"))
 	       (to (mail-fetch-field "to"))
 	       (to (mail-fetch-field "to"))
 	       (subject (mail-fetch-field "subject"))
 	       (subject (mail-fetch-field "subject"))
+	       (date (mail-fetch-field "date"))
+	       (date-ts (and date (format-time-string
+				   (org-time-stamp-format t)
+				   (date-to-time date))))
+	       (date-ts-ia (and date (format-time-string
+				      (org-time-stamp-format t t)
+				      (date-to-time date))))
 	       desc link)
 	       desc link)
 	  (org-store-link-props
 	  (org-store-link-props
 	   :type "rmail" :from from :to to
 	   :type "rmail" :from from :to to
 	   :subject subject :message-id message-id)
 	   :subject subject :message-id message-id)
+	  (when date
+	    (org-add-link-props :date date :date-timestamp date-ts
+				:date-timestamp-inactive date-ts-ia))
 	  (setq message-id (org-remove-angle-brackets message-id))
 	  (setq message-id (org-remove-angle-brackets message-id))
 	  (setq desc (org-email-link-description))
 	  (setq desc (org-email-link-description))
 	  (setq link (org-make-link "rmail:" folder "#" message-id))
 	  (setq link (org-make-link "rmail:" folder "#" message-id))

+ 10 - 0
lisp/org-vm.el

@@ -66,9 +66,19 @@
 	     (to (vm-get-header-contents message "To"))
 	     (to (vm-get-header-contents message "To"))
 	     (from (vm-get-header-contents message "From"))
 	     (from (vm-get-header-contents message "From"))
 	     (message-id (vm-su-message-id message))
 	     (message-id (vm-su-message-id message))
+	     (date (vm-get-header-contents message "Date"))
+	     (date-ts (and date (format-time-string
+				 (org-time-stamp-format t)
+				 (date-to-time date))))
+	     (date-ts-ia (and date (format-time-string
+				    (org-time-stamp-format t t)
+				    (date-to-time date))))
 	     desc link)
 	     desc link)
 	(org-store-link-props :type "vm" :from from :to to :subject subject
 	(org-store-link-props :type "vm" :from from :to to :subject subject
 			      :message-id message-id)
 			      :message-id message-id)
+	(when date
+	  (org-add-link-props :date date :date-timestamp date-ts
+			      :date-timestamp-inactive date-ts-ia))
 	(setq message-id (org-remove-angle-brackets message-id))
 	(setq message-id (org-remove-angle-brackets message-id))
 	(setq folder (abbreviate-file-name folder))
 	(setq folder (abbreviate-file-name folder))
 	(if (and vm-folder-directory
 	(if (and vm-folder-directory

+ 11 - 1
lisp/org-wl.el

@@ -140,7 +140,7 @@ folder name determines the the folder type."
   "Return content of FIELD in ENTITY.
   "Return content of FIELD in ENTITY.
 FIELD is a symbol of a rfc822 message header field.
 FIELD is a symbol of a rfc822 message header field.
 ENTITY is a message entity."
 ENTITY is a message entity."
-  (let ((content (elmo-message-entity-field entity field)))
+  (let ((content (elmo-message-entity-field entity field 'string)))
     (if (listp content) (car content) content)))
     (if (listp content) (car content) content)))
 
 
 (defun org-wl-store-link ()
 (defun org-wl-store-link ()
@@ -199,6 +199,13 @@ ENTITY is a message entity."
 		 (to (org-wl-message-field 'to wl-message-entity))
 		 (to (org-wl-message-field 'to wl-message-entity))
 		 (xref (org-wl-message-field 'xref wl-message-entity))
 		 (xref (org-wl-message-field 'xref wl-message-entity))
 		 (subject (org-wl-message-field 'subject wl-message-entity))
 		 (subject (org-wl-message-field 'subject wl-message-entity))
+		 (date (org-wl-message-field 'date wl-message-entity))
+		 (date-ts (and date (format-time-string
+				     (org-time-stamp-format t)
+				     (date-to-time date))))
+		 (date-ts-ia (and date (format-time-string
+					(org-time-stamp-format t t)
+					(date-to-time date))))
 		 desc link)
 		 desc link)
 
 
 	    ;; remove text properties of subject string to avoid possible bug
 	    ;; remove text properties of subject string to avoid possible bug
@@ -238,6 +245,9 @@ ENTITY is a message entity."
 	      (setq desc (org-email-link-description))
 	      (setq desc (org-email-link-description))
 	      (setq link (org-make-link "wl:" folder-name "#" message-id-no-brackets))
 	      (setq link (org-make-link "wl:" folder-name "#" message-id-no-brackets))
 	      (org-add-link-props :link link :description desc)))
 	      (org-add-link-props :link link :description desc)))
+	    (when date
+	      (org-add-link-props :date date :date-timestamp date-ts
+				  :date-timestamp-inactive date-ts-ia))
 	    (or link xref)))))))
 	    (or link xref)))))))
 
 
 (defun org-wl-open-nntp (path)
 (defun org-wl-open-nntp (path)

+ 9 - 4
lisp/org.el

@@ -10463,7 +10463,7 @@ This function can be used in a hook."
     "BEGIN_VERSE" "END_VERSE"
     "BEGIN_VERSE" "END_VERSE"
     "BEGIN_CENTER" "END_CENTER"
     "BEGIN_CENTER" "END_CENTER"
     "BEGIN_SRC" "END_SRC"
     "BEGIN_SRC" "END_SRC"
-    "CATEGORY" "COLUMNS"
+    "CATEGORY" "COLUMNS" "PROPERTY"
     "CAPTION" "LABEL"
     "CAPTION" "LABEL"
     "SETUPFILE"
     "SETUPFILE"
     "BIND"
     "BIND"
@@ -10582,8 +10582,10 @@ At all other locations, this simply calls the value of
 	       (throw 'exit t)))
 	       (throw 'exit t)))
 	    (tag (and (equal (char-before beg1) ?:)
 	    (tag (and (equal (char-before beg1) ?:)
 		      (equal (char-after (point-at-bol)) ?*)))
 		      (equal (char-after (point-at-bol)) ?*)))
-	    (prop (and (equal (char-before beg1) ?:)
-		       (not (equal (char-after (point-at-bol)) ?*))))
+	    (prop (or (and (equal (char-before beg1) ?:)
+			   (not (equal (char-after (point-at-bol)) ?*)))
+		      (string-match "^#\\+PROPERTY:.*"
+				    (buffer-substring (point-at-bol) (point)))))
 	    (texp (equal (char-before beg) ?\\))
 	    (texp (equal (char-before beg) ?\\))
 	    (link (equal (char-before beg) ?\[))
 	    (link (equal (char-before beg) ?\[))
 	    (opt (equal (buffer-substring (max (point-at-bol) (- beg 2))
 	    (opt (equal (buffer-substring (max (point-at-bol) (- beg 2))
@@ -10660,7 +10662,10 @@ At all other locations, this simply calls the value of
 		  (delete-window (get-buffer-window "*Completions*")))
 		  (delete-window (get-buffer-window "*Completions*")))
 	      (if (assoc completion table)
 	      (if (assoc completion table)
 		  (if (eq type :todo) (insert " ")
 		  (if (eq type :todo) (insert " ")
-		    (if (memq type '(:tag :prop)) (insert ":"))))
+		    (if (and (memq type '(:tag :prop))
+			     (not (string-match "^#[ \t]*\\+property:"
+						(org-current-line-string t))))
+			(insert ":"))))
 	      (if (and (equal type :opt) (assoc completion table))
 	      (if (and (equal type :opt) (assoc completion table))
 		  (message "%s" (substitute-command-keys
 		  (message "%s" (substitute-command-keys
 				 "Press \\[org-complete] again to insert example settings"))))
 				 "Press \\[org-complete] again to insert example settings"))))