branch: externals/org-contacts commit 2d7db49d661fec9971fe488f8485e75185334f05 Author: stardiviner <numbch...@gmail.com> Commit: stardiviner <numbch...@gmail.com>
add new CATEGORIES into vCard export format --- org-contacts.el | 2 ++ 1 file changed, 2 insertions(+) diff --git a/org-contacts.el b/org-contacts.el index 8c0e815ae5..8f0412702e 100644 --- a/org-contacts.el +++ b/org-contacts.el @@ -1322,6 +1322,7 @@ to do our best." (bday (org-contacts-vcard-escape (cdr (assoc-string org-contacts-birthday-property properties)))) (addr (cdr (assoc-string org-contacts-address-property properties))) (nick (org-contacts-vcard-escape (cdr (assoc-string org-contacts-nickname-property properties)))) + (categories (mapconcat (lambda (str) (concat " " str)) (delq "" (string-split (cdr (assoc-string "TAGS" properties)) ":")))) (head (format "BEGIN:VCARD\nVERSION:3.0\nN:%s\nFN:%s\n" n name)) emails-list result phones-list) (concat @@ -1354,6 +1355,7 @@ to do our best." (calendar-extract-month cal-bday) (calendar-extract-day cal-bday)))) (when nick (format "NICKNAME:%s\n" nick)) + (when categories (format "CATEGORIES:%s\n" categories)) (when note (format "NOTE:%s\n" note)) "END:VCARD\n\n")))