emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/ebdb 615ed9a 326/350: Prefix arg to article snarfing on


From: Eric Abrahamsen
Subject: [elpa] externals/ebdb 615ed9a 326/350: Prefix arg to article snarfing only snarfs signature
Date: Mon, 14 Aug 2017 11:47:04 -0400 (EDT)

branch: externals/ebdb
commit 615ed9a213cd1ae0e791f45669d74e57162bff3b
Author: Eric Abrahamsen <address@hidden>
Commit: Eric Abrahamsen <address@hidden>

    Prefix arg to article snarfing only snarfs signature
    
    * ebdb-mua.el (ebdb-mua-snarf-article): Accept a prefix arg. If
      present, only snarf the signature, not the article body.
    * ebdb.org: Mention in manual.
    * ebdb.texi: etc
    * ebdb.info: Actually, I forgot to re-produce the manual last time I
      made changes.
---
 ebdb-mua.el | 11 +++++++----
 ebdb.info   | 41 +++++++++++++++++++++--------------------
 ebdb.org    |  3 ++-
 ebdb.texi   | 11 ++++++-----
 4 files changed, 36 insertions(+), 30 deletions(-)

diff --git a/ebdb-mua.el b/ebdb-mua.el
index 2072f69..d711201 100644
--- a/ebdb-mua.el
+++ b/ebdb-mua.el
@@ -1080,7 +1080,7 @@ where it was in the MUA, rather than quitting the EBDB 
buffer."
       (ebdb-redisplay-records records 'reformat t))))
 
 ;;;###autoload
-(defun ebdb-mua-snarf-article ()
+(defun ebdb-mua-snarf-article (&optional arg)
   "Snarf the body of the current article.
 
 This snarfs all available record information in the article,
@@ -1089,8 +1089,10 @@ of the article, afterwards prompting for the creation of 
new
 records.
 
 In addition, if a signature is present, snarf it and attempt at
-associate field information in it with the article sender."
-  (interactive)
+associate field information in it with the article sender.
+
+With a prefix arg, only snarf the signature."
+  (interactive "P")
   (condition-case nil
       ;; If the MUA has already popped up a buffer, assume the records
       ;; displayed there are relevant to the article snarf.
@@ -1105,7 +1107,8 @@ associate field information in it with the article 
sender."
        (ebdb-mua-prepare-article)
        (unless (or (null (stringp signature)) (string-blank-p signature))
          (ebdb-snarf signature nil nil sender))
-       (ebdb-snarf (ebdb-mua-article-body) nil nil all-recs))
+       (unless arg
+         (ebdb-snarf (ebdb-mua-article-body) nil nil all-recs)))
     (cl-no-applicable-method
      (message "Article snarfing doesn't work in this context."))))
 
diff --git a/ebdb.info b/ebdb.info
index f322754..2b2c062 100644
--- a/ebdb.info
+++ b/ebdb.info
@@ -1122,11 +1122,11 @@ File: ebdb.info,  Node: Snarfing,  Next: 
Internationalization,  Prev: Completion
 “Snarfing” refers to scanning free-form text and extracting information
 related to EBDB records from it.  For example, calling ‘ebdb-snarf’
 while the region contains the text “John Doe <address@hidden>” will
-find an existing matching contact, or prompt to create a new contact,
-and then display it.
+find an existing contact or prompt to create a new one, and then display
+that contact.
 
-   Snarfing is a work in progress: at present, only mail addresses (and
-nearby names) are acted upon, and it often doesn’t work correctly.
+   Snarfing is a work in progress: at present, only mail addresses, URLs
+and nearby names are acted upon, and it often doesn’t work correctly.
 
  -- Command: ebdb-snarf &optional string start end recs
 
@@ -1158,7 +1158,8 @@ article headers.
  -- Command: ebdb-mua-snarf-article
 
      Snarf the body of the current article.  This will also snarf the
-     headers of forwarded emails.
+     headers of forwarded emails, and the signature.  With a prefix
+     argument, only snarf the signature.
 
 
 File: ebdb.info,  Node: Internationalization,  Next: Diary Integration,  Prev: 
Snarfing,  Up: Top
@@ -1829,21 +1830,21 @@ Node: Marking34425
 Node: Exporting/Formatting34853
 Node: Completion35812
 Node: Snarfing36953
-Node: Internationalization38857
-Node: Writing Internationalization Libraries40335
-Node: Diary Integration44623
-Node: Mail Aliases45489
-Node: vCard Support46198
-Node: Org Integration46697
-Node: Citing Records48271
-Node: Hacking EBDB49030
-Node: Field Classes51280
-Node: Init and Delete Methods54170
-Node: The Labeled Field Class55726
-Node: Actions56562
-Node: Custom Field Searching57227
-Node: Formatting in the EBDB Buffer59015
-Node: Index61014
+Node: Internationalization38932
+Node: Writing Internationalization Libraries40410
+Node: Diary Integration44698
+Node: Mail Aliases45564
+Node: vCard Support46273
+Node: Org Integration46772
+Node: Citing Records48346
+Node: Hacking EBDB49105
+Node: Field Classes51355
+Node: Init and Delete Methods54245
+Node: The Labeled Field Class55801
+Node: Actions56637
+Node: Custom Field Searching57302
+Node: Formatting in the EBDB Buffer59090
+Node: Index61089
 
 End Tag Table
 
diff --git a/ebdb.org b/ebdb.org
index 5a58ae8..47ab7fa 100644
--- a/ebdb.org
+++ b/ebdb.org
@@ -874,7 +874,8 @@ article headers.
 - Command: ebdb-mua-snarf-article
 
   Snarf the body of the current article.  This will also snarf the
-  headers of forwarded emails.
+  headers of forwarded emails, and the signature.  With a prefix
+  argument, only snarf the signature.
 * Internationalization
 #+CINDEX: Internationalization
 EBDB comes with an internationalization framework that can provide
diff --git a/ebdb.texi b/ebdb.texi
index aa85154..521ff39 100644
--- a/ebdb.texi
+++ b/ebdb.texi
@@ -1224,11 +1224,11 @@ currently-loaded completion frameworks.
 ``Snarfing'' refers to scanning free-form text and extracting
 information related to EBDB records from it.  For example, calling
 @code{ebdb-snarf} while the region contains the text ``John Doe
-<j.doe@@email.com>'' will find an existing matching contact, or prompt
-to create a new contact, and then display it.
+<j.doe@@email.com>'' will find an existing contact or prompt to create a
+new one, and then display that contact.
 
-Snarfing is a work in progress: at present, only mail addresses (and
-nearby names) are acted upon, and it often doesn't work correctly.
+Snarfing is a work in progress: at present, only mail addresses, URLs
+and nearby names are acted upon, and it often doesn't work correctly.
 
 @cindex ebdb-snarf &optional string start end recs
 @deffn Command ebdb-snarf &optional string start end recs
@@ -1265,7 +1265,8 @@ article headers.
 @deffn Command ebdb-mua-snarf-article
 
 Snarf the body of the current article.  This will also snarf the
-headers of forwarded emails.
+headers of forwarded emails, and the signature.  With a prefix
+argument, only snarf the signature.
 @end deffn
 
 @node Internationalization



reply via email to

[Prev in Thread] Current Thread [Next in Thread]