jwiegley / gnus-harvest

Harvest e-mail addresses from read/written Gnus articles
5 stars 6 forks source link

Feature request: manipulate database from Emacs #2

Open pank opened 12 years ago

pank commented 12 years ago

Gnus harvest is great and on my system it has basically made bbdb3 obsolete (at least for email completion).

It would be nice if it was possible to do some interaction with the database from within Emacs; in particular to delete entries. Alternatively, just a line in the commendatory on how to open .addrs in the terminal.

Use case: a contact of mine recently changed from one office to the other and thus had to change his email. Now I have two entries, of which one of them is preferred. I would like to delete the old one so that I don't use it.

I'm am not sure how much work this would require, as it may (probably) involve creating a `blacklist' of email addresses never to be added to the database...

Thanks, Rasmus

jwiegley commented 12 years ago

Rasmus reply@reply.github.com writes:

It would be nice if it was possible to do some interaction with the database from within Emacs; in particular to delete entries. Alternatively, just a line in the commendatory on how to open .addrs in the terminal.

sqlite3 .addrs

Use case: a contact of mine recently changed from one office to the other and thus had to change his email. Now I have two entries, of which one of them is preferred. I would like to delete the old one so that I don't use it.

delete from addrs where email = 'email@foo.com';

I'm am not sure how much work this would require, as it may (probably) involve creating a `blacklist' of email addresses never to be added to the database...

It's really not meant to be all that smart on the Lisp side. If you use a mailrc file, you can provide shortcuts for often-used addresses that will always expand to the right address.

John