* Re: content management in emacs
[not found] <mailman.47.1614445226.20994.emacs-orgmode@gnu.org>
@ 2021-02-27 18:57 ` Ian Garmaise
2021-02-27 19:16 ` Martin Steffen
` (3 more replies)
2021-02-27 20:52 ` contact " dalanicolai
1 sibling, 4 replies; 9+ messages in thread
From: Ian Garmaise @ 2021-02-27 18:57 UTC (permalink / raw)
To: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 1804 bytes --]
Hi Bob,
How do you send mail to mailing lists with BBDB? Do you use a templating
tool? Also, how do you start a phone call?
Ian
Message: 28
> Date: Sat, 27 Feb 2021 06:53:57 -1000
> From: Bob Newell <bobnewell@bobnewell.net>
> To: "emacs-orgmode" <emacs-orgmode@gnu.org>
> Subject: Re: contact management in emacs
> Message-ID: <s6jv9ad1mfu.fsf@emailmessageidheader.nil>
> Content-Type: text/plain
>
> I've used BBDB for years, and have tried org-contact, but it
> didn't seem to scale to the now rather large size of my BBDB
> database.
>
> I've looked at migrating to EBDB but as I have many custom
> functions I haven't yet made the move.
>
> BBDB can do amazing things. I've mentioned some of them
> before. Of course org links are supported, and in conjunction
> with the 'gnorb' package, Gnus email can be associated with
> BBDB entries in interesting ways.
>
> I use BBDB to easily maintain a slew of mailing lists. I also
> have custom functions to set the input language mode for those
> with whom I correspond in non-English languages. I even use
> BBDB to initiate phone calls when I'm on my desktop computer.
>
> I hadn't thought to put BBDB under version control but that
> would be very easy.
>
> However you don't need to get fancy right away. All the basics
> are there. Like many things Emacs, it does take time to get
> things set up the way you wish, but that time is well repaid
> down the road a little.
>
> --
> Bob Newell
> Honolulu, Hawai`i
>
> - Via GNU/Linux/Emacs/Gnus/BBDB
>
>
>
> End of Emacs-orgmode Digest, Vol 180, Issue 30
> **********************************************
>
--
=====
Ian Garmaise
Consultant
Phorix Solutions Group
ian.g@phorixsol.com
Toronto cell: 416.432.2251
NYC: 917.512.9535
https://www.linkedin.com/in/igarmaise/
http://www.PhorixSol.com
[-- Attachment #2: Type: text/html, Size: 3207 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: content management in emacs
2021-02-27 18:57 ` content management in emacs Ian Garmaise
@ 2021-02-27 19:16 ` Martin Steffen
2021-02-27 20:11 ` Juan Manuel Macías
2021-03-01 5:17 ` Bob Newell
2021-02-28 10:39 ` Eric S Fraga
` (2 subsequent siblings)
3 siblings, 2 replies; 9+ messages in thread
From: Martin Steffen @ 2021-02-27 19:16 UTC (permalink / raw)
To: Ian Garmaise; +Cc: emacs-orgmode
>>>>> "Ian" == Ian Garmaise <ian.g@phorixsol.com> writes:
Ian> Hi Bob,
Ian> How do you send mail to mailing lists with BBDB? Do you use a
I am not sure about the question. If I send to an email list, it's an
address in BBDB. So I ``invoke'' BBDB (M-x bbdb) and give it the name of
the entry (say org-mode). That's analogous to send to a person: If you
remember the name (or part of the name), you find the entry, send then
compose an email ("m") on the entry.
Tab-completion may help.
If the question is: how do I send an email to all members of my chess
club or drinking buddies? If you have added some field to persons of
that circle (like "bridgeclub" or "drinkingbuddy", then you invoke bbdb
with that match, and then there is a possibility to send an email to
/all/ members of a matching list.
For phoning, I am not sure. I think there is (or was) a functionality to
initiate a call (probably with skype or ekiga or some such) but I never
used that.
Basically, for phoning, for me it's more like a rolodex, but a fast and
big one
Martin
Ian> templating tool? Also, how do you start a phone call?
Ian> Ian
Ian> Message: 28 Date: Sat, 27 Feb 2021 06:53:57 -1000 From: Bob
Ian> Newell <bobnewell@bobnewell.net> To: "emacs-orgmode"
Ian> <emacs-orgmode@gnu.org> Subject: Re: contact management in
Ian> emacs Message-ID: <s6jv9ad1mfu.fsf@emailmessageidheader.nil>
Ian> Content-Type: text/plain
Ian> I've used BBDB for years, and have tried org-contact, but it
Ian> didn't seem to scale to the now rather large size of my BBDB
Ian> database.
Ian> I've looked at migrating to EBDB but as I have many custom
Ian> functions I haven't yet made the move.
Ian> BBDB can do amazing things. I've mentioned some of them
Ian> before. Of course org links are supported, and in conjunction
Ian> with the 'gnorb' package, Gnus email can be associated with
Ian> BBDB entries in interesting ways.
Ian> I use BBDB to easily maintain a slew of mailing lists. I also
Ian> have custom functions to set the input language mode for those
Ian> with whom I correspond in non-English languages. I even use
Ian> BBDB to initiate phone calls when I'm on my desktop computer.
Ian> I hadn't thought to put BBDB under version control but that
Ian> would be very easy.
Ian> However you don't need to get fancy right away. All the basics
Ian> are there. Like many things Emacs, it does take time to get
Ian> things set up the way you wish, but that time is well repaid
Ian> down the road a little.
Ian> -- Bob Newell Honolulu, Hawai`i
Ian> - Via GNU/Linux/Emacs/Gnus/BBDB
Ian> End of Emacs-orgmode Digest, Vol 180, Issue 30
Ian> **********************************************
Ian> -- ===== Ian Garmaise Consultant Phorix Solutions Group
Ian> ian.g@phorixsol.com Toronto cell: 416.432.2251 NYC:
Ian> 917.512.9535
Ian> https://www.linkedin.com/in/igarmaise/
Ian> http://www.PhorixSol.com
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: content management in emacs
2021-02-27 19:16 ` Martin Steffen
@ 2021-02-27 20:11 ` Juan Manuel Macías
2021-03-01 5:17 ` Bob Newell
1 sibling, 0 replies; 9+ messages in thread
From: Juan Manuel Macías @ 2021-02-27 20:11 UTC (permalink / raw)
To: Martin Steffen; +Cc: orgmode
Martin Steffen <msteffen@ifi.uio.no> writes:
> I am not sure about the question. If I send to an email list, it's an
> address in BBDB. So I ``invoke'' BBDB (M-x bbdb) and give it the name of
> the entry (say org-mode). That's analogous to send to a person: If you
> remember the name (or part of the name), you find the entry, send then
> compose an email ("m") on the entry.
There is also helm-bbdb, wich is very useful
(https://github.com/emacs-helm/helm-bbdb). For Gnus I have defined this:
#+begin_src emacs-lisp
(require 'helm-bbdb)
(setq message-completion-alist '(("^\\(Newsgroups\\|Followup-To\\|Posted-To\\|Gcc\\):" . message-expand-group)
("^\\(Resent-\\)?\\(To\\|B?Cc\\):" . helm-bbdb-expand-name)
("^\\(Reply-To\\|From\\|Mail-Followup-To\\|Mail-Copies-To\\):" . helm-bbdb-expand-name)
("^\\(Disposition-Notification-To\\|Return-Receipt-To\\):"
. helm-bbdb-expand-name)))
#+end_src
And to insert an address at point (for example, in Org, in the `mail_to'
property):
#+begin_src emacs-lisp
(defun my-insert-mail-address-helm-bbdb (_candidate)
(save-window-excursion
(helm-bbdb--view-person-action-1 (helm-bbdb--marked-contacts))
(call-interactively 'bbdb-mail-address)
(kill-buffer))
(yank))
(add-to-list 'helm-bbdb-actions '("Insert mail address" . my-insert-mail-address-helm-bbdb))
#+end_src
Regards,
Juan Manuel
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: contact management in emacs
[not found] <mailman.47.1614445226.20994.emacs-orgmode@gnu.org>
2021-02-27 18:57 ` content management in emacs Ian Garmaise
@ 2021-02-27 20:52 ` dalanicolai
2021-03-07 22:51 ` Jean Louis
1 sibling, 1 reply; 9+ messages in thread
From: dalanicolai @ 2021-02-27 20:52 UTC (permalink / raw)
To: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 43245 bytes --]
I think all packages fulfill your requirements. So I would say it depends
on how many contacts you are managing. I have some experience with
org-contacts, and I find it very convenient and straightforward. It is also
very convenient to just use org-mode, i.e. a plain text file, for your
contacts. Every contact is a headline and you can add any kind of property
or tag etc. you want. Also anniversaries get added to the Agenda. You can
very easily jump to the right contact, using imenu or swoop/swiper (I use
`SPC j i ` in Spacemacs. So if you have less than say 300 contacts (I have
really no clue about the number of contacts that will still work smoothly),
then depending on how die-hard you are, I would recommend to start with
org-contacs. You can use org-vcard to import contacts, and org-vcard claims
to support exports too but I did not test that yet.
Anyway, I think you won't loose much time with setting up org-contacts and
from then you can slowly check out and study the other options.
I do not use Emacs for email yet, but org-contacts claims to support most
of Emacs its mail-readers.
If you enjoy tweaking your setup and study a little more then maybe
directly use BBDB or EBDB. EBDB's goal is to be a modern BBDB and I guess
the main developer does a very nice job. I have no experience with these
databases, because I think they are overkill (currently) for my usecase.
Daniel Nicolai
On Sat, 27 Feb 2021 at 18:03, <emacs-orgmode-request@gnu.org> wrote:
> Send Emacs-orgmode mailing list submissions to
> emacs-orgmode@gnu.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
> https://lists.gnu.org/mailman/listinfo/emacs-orgmode
> or, via email, send a message with subject or body 'help' to
> emacs-orgmode-request@gnu.org
>
> You can reach the person managing the list at
> emacs-orgmode-owner@gnu.org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Emacs-orgmode digest..."
>
>
> Today's Topics:
>
> 1. Re: Turning off all indentation in 9.4.4 (TRS-80)
> 2. Re: Tips on maintaining history in Org Mode (TRS-80)
> 3. Re: Set archive location relative to property (TRS-80)
> 4. [PATCH] ~org-font-lock-add-priority-faces~: ensure priority
> cookies are in a headline (Sébastien Miquel)
> 5. Re: Tips on maintaining history in Org Mode (Samuel Wales)
> 6. Re: Tips on maintaining history in Org Mode (David Masterson)
> 7. Re: Tips on maintaining history in Org Mode (David Masterson)
> 8. Re: Tips on maintaining history in Org Mode (David Masterson)
> 9. Re: Tips on maintaining history in Org Mode (Tim Cross)
> 10. [bug] org-yank in stars corrupts outline (Samuel Wales)
> 11. Re: [bug] org-yank in stars corrupts outline (Samuel Wales)
> 12. Re: Tips on maintaining history in Org Mode (David Masterson)
> 13. Re: Tips on maintaining history in Org Mode (Samuel Wales)
> 14. Re: Tips on maintaining history in Org Mode (Ihor Radchenko)
> 15. Re: Tips on maintaining history in Org Mode (Ihor Radchenko)
> 16. Re: Tips on maintaining history in Org Mode (Ihor Radchenko)
> 17. contact management in emacs (Alan Schmitt)
> 18. Simple org-publish configuration example in manual does not
> work (dalanicolai)
> 19. Re: contact management in emacs (Martin Steffen)
> 20. Re: [bug] org-yank in stars corrupts outline (Maxim Nikulin)
> 21. Re: [PATCH] org-mac-link: Disable Evernote capture by default
> (Aaron Jensen)
> 22. Re: Babel: Programmatically evaluate a heading and subtrees?
> (ian martins)
> 23. Re: contact management in emacs (andrés ramírez)
> 24. ob-reticulate: R+Python interface from Babel (Jack Kamm)
> 25. Re: contact management in emacs (Eric S Fraga)
> 26. Re: contact management in emacs (andrés ramírez)
> 27. Re: contact management in emacs (Martin Steffen)
> 28. Re: contact management in emacs (Bob Newell)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Fri, 26 Feb 2021 14:12:09 -0500
> From: TRS-80 <lists.trs-80@isnotmyreal.name>
> To: emacs-orgmode@gnu.org
> Subject: Re: Turning off all indentation in 9.4.4
> Message-ID: <83f49a373d71c4b786bda1ad6323ca87@isnotmyreal.name>
> Content-Type: text/plain; charset=US-ASCII; format=flowed
>
> On 2021-02-26 01:20, Kyle Meyer wrote:
> > TRS-80 writes:
> >
> >> On 2021-02-24 15:58, TRS-80 wrote:
> >>> On 2021-02-16 23:30, Kyle Meyer wrote:
> > [...]
> >>>> So, if I'm reading your preferences correctly, it sounds like you
> >>>> want
> >>>> just the first suggestion in the above snippet, leaving
> >>>> org-adapt-indentation at its default value:
> >>>>
> >>>> (add-hook 'org-mode-hook (lambda () (electric-indent-local-mode
> >>>> -1)))
> >>>
> >>> OK, I just did eval-expression (M-:) with (electric-indent-local-mode
> >>> -1) in an Orgmode buffer. After very brief testing, it does indeed
> >>> seem to return the desired behavior. So thanks a lot for that tip!
> > [...]
> >> OK, so after that yesterday, I went ahead and added
> >> (electric-indent-local-mode -1) to my org-mode hook. Then today upon
> >> re-starting Emacs, I am back to not working.
> >>
> >> By not working I mean: Pressing enter goes to column 0 as it should,
> >> however then pressing <TAB> does nothing. Where previously it would
> >> jump to same level as indented above.
> >>
> >> My settings are:
> >>
> >> - electric-indent-local-mode nil (local in each Orgmode buffer, set
> >> via
> >> hook)
> >>
> >> - org-adapt-indentation 'headline-data
> >
> > I'm just repeating my suggestion from above, but perhaps you want to
> > leave org-adapt-indentation at its default value of t?
>
> Apologies, I had skipped right over that bit!
>
> Doing as you say appears (after very brief test just now) to have given
> me back all the expected behavior:
>
> - RET goes to column zero
>
> - TAB goes to indentation level
>
> - Logbook entries are indented as they should be
>
> However in the course of doing this, it reminded me of what I was trying
> to do in the first place, which I thought I could accomplish with some
> of the new functionality (headline-data in particular).
>
> In my mind at least, the headline data belongs "with" the headline. So
> all drawers like LOGBOOK and PROPERTIES (and their respective entries,
> of course) should all be indented to same level as headline.
>
> Now, I used to think the same way about the body text, but I changed my
> mind a year or two (maybe more) ago, as I realized that was just wasting
> too mych space.
>
> So, my reading of this new(?) headline-data setting, was that it seemed
> to be exactly what I had been looking for! But perhaps I misunderstood?
>
> Cheers,
> TRS-80
>
>
>
> ------------------------------
>
> Message: 2
> Date: Fri, 26 Feb 2021 14:24:14 -0500
> From: TRS-80 <lists.trs-80@isnotmyreal.name>
> To: emacs-orgmode@gnu.org
> Subject: Re: Tips on maintaining history in Org Mode
> Message-ID: <45e4dc6434becb1552adc7df544db01a@isnotmyreal.name>
> Content-Type: text/plain; charset=US-ASCII; format=flowed
>
> On 2021-02-26 01:22, David Masterson wrote:
> > There are many ways of maintaining history in a group of Org files:
> > 1. Archive within a file
> > 2. Archive to a separate (archive) file
> > 3. Special TODO types for history
> > 4. Special TAG types for history
> > 5. etc.
> >
> > My question is, if you have meetings/phone calls as TODOs, what is the
> > preferred way to handle when they move into history so that, *much*
> > later, you can easily produce a list of all of the meetings/phone calls
> > with dates and times of them? The issue (I think) is, when you mark
> > the
> > TODO as DONE, you lose the info of what the TODO was originally.
> >
> > Suggestions
>
> I agree with what others already said about logging state changes with
> timestamps. I do the same and find this an extremely handy place to
> put "metadata about the task, or reason that it changed" and keep it
> separate/hidden from the main body of the task (which in my mind
> should only contain info about the subject of the headline / task
> itself).
>
> However when you say "history" I suspect you mean "archive" and this
> is something I have been thinking about a long time as well. Because
> I think the current way that Orgmode handles this is a bit naive /
> simplistic. Well, at least there is the option to create your own
> archival function, which I suspect I will do at some point. In fact I
> have been thinking about the best way to do that for some time
> already.
>
> Cheers,
> TRS-80
>
>
>
> ------------------------------
>
> Message: 3
> Date: Fri, 26 Feb 2021 14:30:56 -0500
> From: TRS-80 <lists.trs-80@isnotmyreal.name>
> To: emacs-orgmode@gnu.org
> Subject: Re: Set archive location relative to property
> Message-ID: <565b3cb59087b33087676d8059a7e39d@isnotmyreal.name>
> Content-Type: text/plain; charset=UTF-8; format=flowed
>
> On 2021-02-25 15:49, Florian Lindner wrote:
> > Am 25.02.21 um 21:22 schrieb Florian Lindner:
> >> is this possible with org-mode? Given a tree:
> >>
> >> * Name
> >> :PROPERTIES:
> >> :ARCHIVE: ???
> >> :END:
> >> ** Archive :ARCHIVE:
> >> ** Some node
> >>
> >> Upon archiving "Some node" (or any direct or indirect sub-node of
> >> Projectname) I want to end it up under "** Archive". The archive
> >> location should always be relative to the node where the property
> >> ARCHIVE is set.
> >>
> >> The documentation org-archive-location does not suggest that is
> >> possible.
> >
> > An alternative idea would be a setting for the ARCHIVE property that
> > searches the tree upward until it finds a node with an :ARCHIVE: tag
> > and use that as archive location. Maybe indicated by a setting of
> > "::%a".
> >
> > What do you think?
>
> I could be wrong, but my feeling (in either case) is something like
> that would probably require writing a custom archive function.
> Luckily, Orgmode allows you to do that.
>
> Cheers,
> TRS-80
>
>
>
> ------------------------------
>
> Message: 4
> Date: Fri, 26 Feb 2021 20:58:35 +0100
> From: Sébastien Miquel <sebastien.miquel@posteo.eu>
> To: emacs-orgmode@gnu.org
> Cc: Ihor Radchenko <yantar92@gmail.com>
> Subject: [PATCH] ~org-font-lock-add-priority-faces~: ensure priority
> cookies are in a headline
> Message-ID: <a9f0fc01-2f32-8831-ac8b-0f0fe9e00a4d@posteo.eu>
> Content-Type: text/plain; charset="utf-8"; Format="flowed"
>
> Priority cookies are always in a headline.
>
> The attached patch speeds up fontification of a 1k lines buffer by 0.1
> second.
>
> Note that the variable org-priority-regexp can't be modified since
> it is used in the agenda and in org-get-priority.
>
> Regards,
>
> --
> Sébastien Miquel
> -------------- next part --------------
> A non-text attachment was scrubbed...
> Name: 0001-org.el-org-font-lock-add-priority-faces-Speed-up-reg.patch
> Type: text/x-patch
> Size: 967 bytes
> Desc: not available
> URL: <
> https://lists.gnu.org/archive/html/emacs-orgmode/attachments/20210226/9ca34244/attachment.bin
> >
>
> ------------------------------
>
> Message: 5
> Date: Fri, 26 Feb 2021 14:34:43 -0700
> From: Samuel Wales <samologist@gmail.com>
> To: David Masterson <dsmasterson92630@outlook.com>
> Cc: emacs-orgmode@gnu.org
> Subject: Re: Tips on maintaining history in Org Mode
> Message-ID:
> <
> CAJcAo8uAc04c2v4xMhm8PWbp5v3wk3Jz13bDJDkdLFDnVs5kUw@mail.gmail.com>
> Content-Type: text/plain; charset="UTF-8"
>
> org does indeed have a lot of related features, maybe too many even.
> here is some of what i do.
>
> - if i doneify, it means i will likely not need to search for it.
> archived to a file.
> [currently the archiver is so slow i can't use it]
> CLOSED: [2012-11-08 Thu 19:40]
> - state logging for repeaters in logbook
> - your question: notes to keep around like this
> ***** LOG [2021-02-26 Fri 14:18] talked to bill gates; he uses linux now
> these get sorted at bottom by timestamp using user-defined
> this is the main thing
> - bare inactive free form as needed
>
> --
> The Kafka Pandemic
>
> Please learn what misopathy is.
>
> https://thekafkapandemic.blogspot.com/2013/10/why-some-diseases-are-wronged.html
>
>
>
> ------------------------------
>
> Message: 6
> Date: Fri, 26 Feb 2021 14:51:30 -0800
> From: David Masterson <dsmasterson92630@outlook.com>
> To: Ihor Radchenko <yantar92@gmail.com>
> Cc: emacs-orgmode@gnu.org
> Subject: Re: Tips on maintaining history in Org Mode
> Message-ID:
> <
> SJ0PR03MB5455FD17CD8FA3853983D5509B9D9@SJ0PR03MB5455.namprd03.prod.outlook.com
> >
>
> Content-Type: text/plain
>
> Ihor Radchenko <yantar92@gmail.com> writes:
>
> > David Masterson <dsmasterson92630@outlook.com> writes:
> >> My question is, if you have meetings/phone calls as TODOs, what is the
> >> preferred way to handle when they move into history so that, *much*
> >> later, you can easily produce a list of all of the meetings/phone calls
> >> with dates and times of them? The issue (I think) is, when you mark the
> >> TODO as DONE, you lose the info of what the TODO was originally.
> >
> > See Org manual :: 5.3 Progress Logging
>
> Interesting, but then how do you get the list? I mean is there an
> agenda to use?
> --
> David Masterson
>
>
>
> ------------------------------
>
> Message: 7
> Date: Fri, 26 Feb 2021 14:55:16 -0800
> From: David Masterson <dsmasterson92630@outlook.com>
> To: Tim Cross <theophilusx@gmail.com>
> Cc: emacs-orgmode@gnu.org
> Subject: Re: Tips on maintaining history in Org Mode
> Message-ID:
> <
> SJ0PR03MB5455A0B7779A6D32EDB6EC099B9D9@SJ0PR03MB5455.namprd03.prod.outlook.com
> >
>
> Content-Type: text/plain
>
> Tim Cross <theophilusx@gmail.com> writes:
>
> > David Masterson <dsmasterson92630@outlook.com> writes:
> >
> >> There are many ways of maintaining history in a group of Org files:
> >> 1. Archive within a file
> >> 2. Archive to a separate (archive) file
> >> 3. Special TODO types for history
> >> 4. Special TAG types for history
> >> 5. etc.
> >>
> >> My question is, if you have meetings/phone calls as TODOs, what is the
> >> preferred way to handle when they move into history so that, *much*
> >> later, you can easily produce a list of all of the meetings/phone calls
> >> with dates and times of them? The issue (I think) is, when you mark the
> >> TODO as DONE, you lose the info of what the TODO was originally.
> >
> > A lot will depend on your requirements.
> >
> > For me, my TODOs are setup so that they record a date stamp for when
> > they were added and whenever they change state e.g. started, done,
> > delegated etc.
>
> So, you use progress logging.
>
> > For non-TODO items, I will often put an inactive timestamp in the
> > heading title.
>
> Do your headings become busy?
>
> What would you use to then make a list of all meetings you had last year?
>
> --
> David Masterson
>
>
>
> ------------------------------
>
> Message: 8
> Date: Fri, 26 Feb 2021 15:00:02 -0800
> From: David Masterson <dsmasterson92630@outlook.com>
> To: emacs-orgmode@gnu.org
> Subject: Re: Tips on maintaining history in Org Mode
> Message-ID:
> <
> SJ0PR03MB54554F09F1784A4DE894233D9B9D9@SJ0PR03MB5455.namprd03.prod.outlook.com
> >
>
> Content-Type: text/plain
>
> Eric S Fraga <e.fraga@ucl.ac.uk> writes:
>
> > My approach is simple. For TODO items, I archive to separate file when
> > done. That file is easily searchable, e.g. using C-c /.
>
> Ah! org-occur! That's something forgot about and looks useful.
>
> > I keep both the original file and the archive file under revision
> > control, just in case.
>
> I do that, too.
>
> >> The issue (I think) is, when you mark the TODO as DONE, you lose the
> >> info of what the TODO was originally.
> >
> > What info is lost? In fact, if you log state changes, all the
> > information is there.
>
> I see how that workss now with org-occur.
>
> > By the way, if you have recurring items, one package that you might find
> > useful is org-recur which is on ELPA.
>
> Thanks
>
> --
> David Masterson
>
>
>
> ------------------------------
>
> Message: 9
> Date: Sat, 27 Feb 2021 09:59:50 +1100
> From: Tim Cross <theophilusx@gmail.com>
> To: David Masterson <dsmasterson92630@outlook.com>
> Cc: emacs-orgmode@gnu.org
> Subject: Re: Tips on maintaining history in Org Mode
> Message-ID: <87wnuu9zrf.fsf@gmail.com>
> Content-Type: text/plain
>
>
> David Masterson <dsmasterson92630@outlook.com> writes:
>
> > Tim Cross <theophilusx@gmail.com> writes:
> >
> >> David Masterson <dsmasterson92630@outlook.com> writes:
> >>
> >> For me, my TODOs are setup so that they record a date stamp for when
> >> they were added and whenever they change state e.g. started, done,
> >> delegated etc.
> >
> > So, you use progress logging.
>
> Yes.
>
> >
> >> For non-TODO items, I will often put an inactive timestamp in the
> >> heading title.
> >
> > Do your headings become busy?
> >
>
> Some would feel they are 'busy'. I always put the timestamp at the
> beginning of the heading, so there is a regular pattern (not much
> different from the leading heading stars) and I've just got use to it,
> so I don't really see it now.
>
> > What would you use to then make a list of all meetings you had last year?
>
> For me, archiving is about data I'm unlikely to need again, but just in
> case I do, it is in the archive. I rarely look at my archives. However,
> when I do archive, I will usually archive into a 'year' file. So, to
> find all the meetings held in 2015, I would open that archive file and
> search for entries with the tag MEETING (I also have a tag for PHONE).
>
> --
> Tim Cross
>
>
>
> ------------------------------
>
> Message: 10
> Date: Fri, 26 Feb 2021 17:52:37 -0700
> From: Samuel Wales <samologist@gmail.com>
> To: emacs-orgmode@gnu.org
> Subject: [bug] org-yank in stars corrupts outline
> Message-ID:
> <CAJcAo8uF=
> JrtYWfe2HCPpgXcbD5kbGT78wtn67zXB8V_-SGWpg@mail.gmail.com>
> Content-Type: text/plain; charset="UTF-8"
>
> it is neither raw yank behavior nor org syntax
>
> in recent maint
>
> i have org-yank-adjusted-subtrees t
>
> * org-yank is funny
> *** kill this line (with newline) then try yanking at ^ places (remove
> the ^ first)
> the fault lies in the stars
> insertion above and arbitrary demotion
> *** x
> asdfnaksdj fnkadsn fkjans df
> ^a^sdkfjnaksdfn kajsndfk ajdnsf
> askdjfkasjdn fkajfdns
> *^*^* y
> *** [[https://go^ogle.com]]
>
>
>
> ------------------------------
>
> Message: 11
> Date: Fri, 26 Feb 2021 17:54:36 -0700
> From: Samuel Wales <samologist@gmail.com>
> To: emacs-orgmode@gnu.org
> Subject: Re: [bug] org-yank in stars corrupts outline
> Message-ID:
> <CAJcAo8vKRwzP_TAOwxCttC6o82O0g2OwOg_V+ep2E4=
> E3BxFxA@mail.gmail.com>
> Content-Type: text/plain; charset="UTF-8"
>
> *** kill any header (with newline) then try yanking in various places
> in the stars of any indented header that has things above it. you
> should get multiple demotions that do not conform to outline.
>
> On 2/26/21, Samuel Wales <samologist@gmail.com> wrote:
> > it is neither raw yank behavior nor org syntax
> >
> > in recent maint
> >
> > i have org-yank-adjusted-subtrees t
> >
> > * org-yank is funny
> > *** kill this line (with newline) then try yanking at ^ places (remove
> > the ^ first)
> > the fault lies in the stars
> > insertion above and arbitrary demotion
> > *** x
> > asdfnaksdj fnkadsn fkjans df
> > ^a^sdkfjnaksdfn kajsndfk ajdnsf
> > askdjfkasjdn fkajfdns
> > *^*^* y
> > *** [[https://go^ogle.com]]
> >
>
>
> --
> The Kafka Pandemic
>
> Please learn what misopathy is.
>
> https://thekafkapandemic.blogspot.com/2013/10/why-some-diseases-are-wronged.html
>
>
>
> ------------------------------
>
> Message: 12
> Date: Fri, 26 Feb 2021 19:17:34 -0800
> From: David Masterson <dsmasterson92630@outlook.com>
> To: Tim Cross <theophilusx@gmail.com>
> Cc: emacs-orgmode@gnu.org
> Subject: Re: Tips on maintaining history in Org Mode
> Message-ID:
> <
> SJ0PR03MB5455951AD10B7FDB57BD87E39B9C9@SJ0PR03MB5455.namprd03.prod.outlook.com
> >
>
> Content-Type: text/plain
>
> Tim Cross <theophilusx@gmail.com> writes:
>
> > David Masterson <dsmasterson92630@outlook.com> writes:
> >
> >> What would you use to then make a list of all meetings you had last
> year?
> >
> > For me, archiving is about data I'm unlikely to need again, but just in
> > case I do, it is in the archive. I rarely look at my archives. However,
> > when I do archive, I will usually archive into a 'year' file. So, to
> > find all the meetings held in 2015, I would open that archive file and
> > search for entries with the tag MEETING (I also have a tag for PHONE).
>
> Got it. Thanks.
> --
> David Masterson
>
>
>
> ------------------------------
>
> Message: 13
> Date: Fri, 26 Feb 2021 21:21:54 -0700
> From: Samuel Wales <samologist@gmail.com>
> To: David Masterson <dsmasterson92630@outlook.com>
> Cc: Tim Cross <theophilusx@gmail.com>, emacs-orgmode@gnu.org
> Subject: Re: Tips on maintaining history in Org Mode
> Message-ID:
> <CAJcAo8tK7QiKLeBWe9+duQmntr2EER3pGXOJJy_Cx7vDu=
> djpg@mail.gmail.com>
> Content-Type: text/plain; charset="UTF-8"
>
> note that there is an issue when you try to name your archive files
> using years like computer-2000.org_archive. it can take seconds to
> find-file big files so it is understandable to want to name files like
> that.
>
> however, if you change the name of an archive file, it will not be
> found by org when you tell it to do certain things with archive files.
> some code in org derives the basename to search from the basename of
> the original file like computer,org.
>
> in principle, maybe org could allow year suffixes/prefixes or it could
> search all archive files in dirs that have org files.
>
> perhaps also changing org-archive-file-header-format to allow a format
> thingie for a timestamp would allow you to take parts of an archive
> file and move them into one per year without having to put the date in
> each archived entry.
>
>
> On 2/26/21, David Masterson <dsmasterson92630@outlook.com> wrote:
> > Tim Cross <theophilusx@gmail.com> writes:
> >
> >> David Masterson <dsmasterson92630@outlook.com> writes:
> >>
> >>> What would you use to then make a list of all meetings you had last
> >>> year?
> >>
> >> For me, archiving is about data I'm unlikely to need again, but just in
> >> case I do, it is in the archive. I rarely look at my archives. However,
> >> when I do archive, I will usually archive into a 'year' file. So, to
> >> find all the meetings held in 2015, I would open that archive file and
> >> search for entries with the tag MEETING (I also have a tag for PHONE).
> >
> > Got it. Thanks.
> > --
> > David Masterson
> >
> >
>
>
> --
> The Kafka Pandemic
>
> Please learn what misopathy is.
>
> https://thekafkapandemic.blogspot.com/2013/10/why-some-diseases-are-wronged.html
>
>
>
> ------------------------------
>
> Message: 14
> Date: Sat, 27 Feb 2021 14:28:13 +0800
> From: Ihor Radchenko <yantar92@gmail.com>
> To: David Masterson <dsmasterson92630@outlook.com>
> Cc: emacs-orgmode@gnu.org
> Subject: Re: Tips on maintaining history in Org Mode
> Message-ID: <87czwmc9du.fsf@localhost>
> Content-Type: text/plain
>
> David Masterson <dsmasterson92630@outlook.com> writes:
>
> > Interesting, but then how do you get the list? I mean is there an
> > agenda to use?
>
> Generally yes, you can use agenda. Or you can use sparse tree (more
> manual).
> For agenda, if you customise org-log-done, you can use
> org-agenda-log-mode ("v l" or "v L" in an agenda buffer). You can add
> archived items as well with "v a" or/and "v A".
>
> Just org-agenda-log-mode will show everything, not just calls. Narrowing
> to calls only will depend on how you define a todo, which is a call.
>
> If you use something like PHONE or CALL todo keywords, it might be
> slightly tricky. You will need to customise org-todo-keywords, so that
> your CALL->DONE changes are recorded (see the org-todo-keywords
> docstring). You will also need to filter displayed items in agenda by
> regexp involving the keyword you use to define the call.
>
> An easier way could be marking your calls with a tag. Then, you can
> filter your org-agenda-log by that tag to show only calls.
>
> Hope it helps.
>
> Best,
> Ihor
>
>
>
>
> ------------------------------
>
> Message: 15
> Date: Sat, 27 Feb 2021 14:38:47 +0800
> From: Ihor Radchenko <yantar92@gmail.com>
> To: Samuel Wales <samologist@gmail.com>, David Masterson
> <dsmasterson92630@outlook.com>
> Cc: Tim Cross <theophilusx@gmail.com>, emacs-orgmode@gnu.org
> Subject: Re: Tips on maintaining history in Org Mode
> Message-ID: <87a6rqc8w8.fsf@localhost>
> Content-Type: text/plain
>
> Samuel Wales <samologist@gmail.com> writes:
>
> > perhaps also changing org-archive-file-header-format to allow a format
> > thingie for a timestamp would allow you to take parts of an archive
> > file and move them into one per year without having to put the date in
> > each archived entry.
>
> FYI: I have implemented automatic per-year archiving, which is correctly
> handled by other org commands in my personal config:
> https://github.com/yantar92/emacs-config/blob/master/config.org#archiving
>
> Best,
> Ihor
>
>
>
>
> ------------------------------
>
> Message: 16
> Date: Sat, 27 Feb 2021 14:42:03 +0800
> From: Ihor Radchenko <yantar92@gmail.com>
> To: Samuel Wales <samologist@gmail.com>, David Masterson
> <dsmasterson92630@outlook.com>
> Cc: emacs-orgmode@gnu.org
> Subject: Re: Tips on maintaining history in Org Mode
> Message-ID: <877dmuc8qs.fsf@localhost>
> Content-Type: text/plain
>
> Samuel Wales <samologist@gmail.com> writes:
> > [currently the archiver is so slow i can't use it]
>
> Are your existing archives very big (few Mbs)? If so, you may try to
> speed up the archiving using feature/org-fold branch [1]. If that is not
> enough, I recommend splitting archives on yearly basis [2] or disabling
> font-lock in archive files.
>
> Best,
> Ihor
>
> [1] https://github.com/yantar92/org
> [2]
> https://github.com/yantar92/emacs-config/blob/master/config.org#archiving
>
>
>
>
> ------------------------------
>
> Message: 17
> Date: Sat, 27 Feb 2021 12:08:04 +0100
> From: Alan Schmitt <alan.schmitt@polytechnique.org>
> To: "emacs-orgmode" <emacs-orgmode@gnu.org>
> Subject: contact management in emacs
> Message-ID: <87lfb9bwff.fsf@m4x.org>
> Content-Type: text/plain; charset="utf-8"
>
> Hello,
>
> This may be slightly off-topic for the list, but as I’m considering
> org-contacts for my question, I hope it will be of interest here.
>
> I would like to migrate my contact management to emacs, as I’m already
> using it for email. My requirements are the following ones:
> - address completion in emacs email clients (I currently use notmuch)
> - support for multiple email addresses and custom fields
> - creation of org links to contacts
> - export to vcard format for synchronization to my mobile phone (using
> vdirsyncer)
> - keep the data under version control
>
> I have looked at two tools, which almost seem fit for the job.
> - ebdb does most of this, with the exception of vcard export (it seems
> to be worked on, https://github.com/girzel/ebdb/issues/60), and I’m not
> sure using version control on an sqlite file is a good idea.
> - org-contacts also seem to have all the required features, including
> vcard export (and if not sufficient there is
> https://github.com/novoid/org-contacts2vcard). I was worried it was
> unmaintained when looking at the copyright line, but I see in
>
> https://code.orgmode.org/bzg/org-mode/commits/master/contrib/lisp/org-contacts.el
> that there are recent commits to the file.
>
> Do you manage your contacts in emacs? And if so, what tools or workflow
> do you recommend?
>
> Best,
>
> Alan
> -------------- next part --------------
> A non-text attachment was scrubbed...
> Name: signature.asc
> Type: application/pgp-signature
> Size: 528 bytes
> Desc: not available
> URL: <
> https://lists.gnu.org/archive/html/emacs-orgmode/attachments/20210227/1b6fa02c/attachment.sig
> >
>
> ------------------------------
>
> Message: 18
> Date: Sat, 27 Feb 2021 12:08:38 +0100
> From: dalanicolai <dalanicolai@gmail.com>
> To: emacs-orgmode@gnu.org
> Subject: Simple org-publish configuration example in manual does not
> work
> Message-ID:
> <CACJP=3k2jL1z0d-uALFGoutffFF2o=
> 7-L39zUns6si0KAhZ-_g@mail.gmail.com>
> Content-Type: text/plain; charset="utf-8"
>
> Hello, sorry for sending this email directly, but currently sending mail
> from Emacs does not work correctly.
>
>
> I was trying out the org-publishing functionality, but I found that
> the first example in the documentation given at
> https://orgmode.org/manual/Simple-example.html#Simple-example
> does not work. When I try to publish the project it errors with the
> following message
>
> org-publish-file: No publishing function chosen
>
> So I figured that I should add a :publishing-function and I remembered
> reading earlier in the documnetation,
> i.e. at
> https://orgmode.org/manual/Publishing-action.html#Publishing-action
> org-html-publish-to-html
> <https://orgmode.org/manual/Publishing-action.html#Publishing-actionorg-html-publish-to-html>
> that org uses the default publishing-function
>
> org-publish-org-to-html
>
> But when trying to publish using that function then Emacs errors with
> the message
>
> org-publish-file: Symbol’s function definition is void:
> org-publish-org-to-html
>
> I have found the following error report from 17 Mar 2013, reporting
> exactly the same error (and a reply with the solution)
> https://lists.gnu.org/archive/html/emacs-orgmode/2013-03/msg01221.html
>
> It would be great if these two small point in the manual, which is
> otherwise great, could
> get updated.
>
> 1. add the required :publishing-function keyword to the documentation (with
> the correct function value)
> 2. change the name of the default function from org-publish-org-to-html ->
> *org-html-publish-to-html*
>
> Thank you!
>
> Best regards,
> Daniel Nicolai
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <
> https://lists.gnu.org/archive/html/emacs-orgmode/attachments/20210227/02a12cbf/attachment.html
> >
>
> ------------------------------
>
> Message: 19
> Date: Sat, 27 Feb 2021 12:31:05 +0100
> From: Martin Steffen <msteffen@ifi.uio.no>
> To: Alan Schmitt <alan.schmitt@polytechnique.org>
> Cc: emacs-orgmode <emacs-orgmode@gnu.org>
> Subject: Re: contact management in emacs
> Message-ID: <867dmteohy.fsf@login.ifi.uio.no>
> Content-Type: text/plain
>
>
>
>
> I use bbdb (big-brother data base). I use it since a looong time
> already, and amassed 15000 or so contracts. It does what I want, it's
> text-based, so versioning is not a problem.
>
> I think it can do vcard export (though when I used vcards is a long
> time ago, I can't remember if that was smooth, I think it was with one
> of my first smart phone, and I wanted to quick fill up the phone book
> there with my ``emacs-managed'' contact data base.).
>
> One can add used defined fields (where one can ``match'' all contacts
> for some criterion, and send then ``bulk'' email.
>
> Org is also bbdb-aware, insofar one can do those links: instead of
> [[file:xxxx][yyy]] one can use [[bbdb:somecriterion]].
>
> I don't know if it matches your needs, but I can't say bad things about
> that bbdb-thing.
>
> Martin
>
>
>
>
>
> ------------------------------
>
> Message: 20
> Date: Sat, 27 Feb 2021 18:55:54 +0700
> From: Maxim Nikulin <manikulin@gmail.com>
> To: emacs-orgmode@gnu.org
> Subject: Re: [bug] org-yank in stars corrupts outline
> Message-ID: <s1dc0b$udf$1@ciao.gmane.io>
> Content-Type: text/plain; charset=utf-8; format=flowed
>
> On 27/02/2021 07:52, Samuel Wales wrote:
> >
> > i have org-yank-adjusted-subtrees t
> >
> > * org-yank is funny
> > *** kill this line (with newline) then try yanking at ^ places (remove
> > the ^ first)
> > the fault lies in the stars
> > insertion above and arbitrary demotion
> > *** x
> > asdfnaksdj fnkadsn fkjans df
> > ^a^sdkfjnaksdfn kajsndfk ajdnsf
> > askdjfkasjdn fkajfdns
> > *^*^* y
> > *** [[https://go^ogle.com]]
>
> from [[help:org-yank]]
>
> > If it passes the test, and if the
> > cursor is at the beginning of a line or after the stars of a currently
> > empty headline, then the yank is handled specially. How exactly depends
> > on the value of the following variables.
>
> In my opinion, your "^" marks do not satisfy the specified criteria.
>
> Personally I use [[help:org-paste-subtree]] C-c C-x C-y directly. It has
> a minor issue however. First time after emacs start it refuses to yank
> subtree from X clipboard (prepared externally). Regular paste with undo
> C-y C-/ is enough to convince the function that there is a subtree in
> the clipboard. Next time it works without such dance.
>
>
>
>
>
> ------------------------------
>
> Message: 21
> Date: Sat, 27 Feb 2021 07:14:52 -0600
> From: Aaron Jensen <aaronjensen@gmail.com>
> To: emacs-orgmode@gnu.org
> Subject: Re: [PATCH] org-mac-link: Disable Evernote capture by default
> Message-ID:
> <CAHyO48x1rFo_CA_Ha3nZLNeWozurB=+
> 7pS1xOdc3p45nyF-y3Q@mail.gmail.com>
> Content-Type: text/plain; charset="UTF-8"
>
> On Wed, Feb 17, 2021 at 9:55 AM Aaron Jensen <aaronjensen@gmail.com>
> wrote:
> >
> > The two `shell-command-to-string` invocations during eval are
> > extremely slow. Users of Evernote should `org-mac-grab-Evernote-app-p`
> > and `org-mac-evernote-path` explicitly.
>
> Hi all,
>
> Any chance of getting this merged in? It's a pretty nasty one for mac
> users.
>
> Thanks,
>
> Aaron
>
>
>
> ------------------------------
>
> Message: 22
> Date: Sat, 27 Feb 2021 08:18:45 -0500
> From: ian martins <ianxm@jhu.edu>
> To: Nathan Neff <nathan.neff@gmail.com>
> Cc: emacs-orgmode <emacs-orgmode@gnu.org>
> Subject: Re: Babel: Programmatically evaluate a heading and subtrees?
> Message-ID:
> <CAC=rjb4iJPkXjOVAi83jjBrc=
> 4TjEZhr_KrEnYvF_K0GSapHOw@mail.gmail.com>
> Content-Type: text/plain; charset="UTF-8"
>
> Can you use noweb? In the example below, if you run the top code block
> babel will run the two that follow.
>
> A drawback is that you have to redefine variables, but it might be a
> benefit, since the individual blocks could be set with test data and
> the "main driver" could point to real data.
> -------
>
> #+begin_src elisp :results output :noweb yes :var data=data1
> <<fun1>>
> <<fun2>>
> #+end_src
>
> #+RESULTS:
> : called fun1: some data
> : called fun2
>
> #+name: data1
> some data
>
> #+name: fun1
> #+begin_src elisp :var data=data1
> (princ (format "called fun1: %s" data))
> #+end_src
>
> #+name: fun2
> #+begin_src elisp
> (princ "called fun2")
> #+end_src
>
> On Sat, Feb 20, 2021 at 2:11 PM Nathan Neff <nathan.neff@gmail.com> wrote:
> >
> > Hello all,
> >
> > I have some code like this:
> >
> > * Heading 1
> >
> > # code block name:FOO
> >
> > ** Subheading 1
> >
> > # code block
> >
> > ** Subheading 2
> >
> > # code block
> >
> > I find that I often want to evaluate the code in Heading 1 and its
> subheadings.
> >
> > Currently, I navigate to Heading 1 and then use org-babel-execute-subtree
> >
> > I see that there's a function called org-babel-goto-named-src-block, so
> I think
> > I could write a small function to jump to FOO in Heading 1 and then run
> execute subtree
> > and then jump back to my previous location in Emacs.
> >
> > Is there a more programmatic or built-in way? For example:
> > org-babel-execute-block-and-subheadings FOO
> >
> > Thanks,
> > --Nate
>
>
>
> ------------------------------
>
> Message: 23
> Date: Sat, 27 Feb 2021 13:20:23 +0000
> From: andrés ramírez <rrandresf@gmail.com>
> To: Martin Steffen <msteffen@ifi.uio.no>
> Cc: Alan Schmitt <alan.schmitt@polytechnique.org>, emacs-orgmode
> <emacs-orgmode@gnu.org>
> Subject: Re: contact management in emacs
> Message-ID: <868s79hcko.fsf@gmail.com>
> Content-Type: text/plain; charset=utf-8
>
> Hi. Martin and Alan.
>
> >>>>> "Martin" == Martin Steffen <msteffen@ifi.uio.no> writes:
>
>
> [...]
>
>
> Martin> Org is also bbdb-aware, insofar one can do those links:
> instead of [[file:xxxx][yyy]]
> Martin> one can use [[bbdb:somecriterion]].
>
> bbdb anniversaries could also appear on agenda:
> --8<---------------cut here---------------start------------->8---
> 10 days-agenda (W08-W09):
> Wednesday 24 February 2021
> Thursday 25 February 2021
> Friday 26 February 2021
> Saturday 27 February 2021
> Sunday 28 February 2021
> Monday 1 March 2021 W09
> Tuesday 2 March 2021
> Wednesday 3 March 2021
> bbdb: [[bbdb:Pedro ][Pedro 61st custom anniversary]]
> Thursday 4 March 2021
> Friday 5 March 2021
> --8<---------------cut here---------------end--------------->8---
>
> Andrés Ramírez
>
>
>
> ------------------------------
>
> Message: 24
> Date: Sat, 27 Feb 2021 06:15:29 -0800
> From: Jack Kamm <jackkamm@gmail.com>
> To: emacs-orgmode@gnu.org
> Subject: ob-reticulate: R+Python interface from Babel
> Message-ID: <87y2f94mwu.fsf@gmail.com>
> Content-Type: text/plain
>
> Hi all,
>
> ob-reticulate is now available on MELPA.
>
> You can find more information here:
> https://github.com/jackkamm/ob-reticulate
>
> Cheers,
> Jack
>
>
>
> ------------------------------
>
> Message: 25
> Date: Sat, 27 Feb 2021 14:40:32 +0000
> From: Eric S Fraga <e.fraga@ucl.ac.uk>
> To: andrés ramírez <rrandresf@gmail.com>
> Cc: emacs-orgmode <emacs-orgmode@gnu.org>
> Subject: Re: contact management in emacs
> Message-ID: <87lfb9y3of.fsf@ucl.ac.uk>
> Content-Type: text/plain; charset=utf-8
>
> On Saturday, 27 Feb 2021 at 13:20, andrés ramírez wrote:
> > bbdb anniversaries could also appear on agenda:
>
> How do you get these to appear? Or is the "could" a wish?
> thank you, eric
> --
> : Eric S Fraga via Emacs 28.0.50, Org release_9.4.4-231-gf46925
>
>
>
> ------------------------------
>
> Message: 26
> Date: Sat, 27 Feb 2021 15:12:00 +0000
> From: andrés ramírez <rrandresf@gmail.com>
> To: andrés ramírez <rrandresf@gmail.com>, emacs-orgmode
> <emacs-orgmode@gnu.org>
> Subject: Re: contact management in emacs
> Message-ID: <868s79zgsf.fsf@gmail.com>
> Content-Type: text/plain
>
> Hi. Eric.
>
> >>>>> "Eric" == Eric S Fraga <e.fraga@ucl.ac.uk> writes:
>
>
> [...]
>
>
> Eric> How do you get these to appear? Or is the "could" a wish?
>
> This is my setup:
> --8<---------------cut here---------------start------------->8---
> (setq org-agenda-files (directory-files "~/docs/org/deft/" t
> ".*agenda\.org$"))
> --8<---------------cut here---------------end--------------->8---
>
> ~/docs/org/deft/bbdb-anniversary-trick.agenda.org:
> --8<---------------cut here---------------start------------->8---
> * anniversary [isodate]
> :PROPERTIES:
> :CATEGORY: bbdb
> :END:
> %%(when (fboundp 'my/org-bbdb-anniversaries) (my/org-bbdb-anniversaries))
> --8<---------------cut here---------------end--------------->8---
>
> --8<---------------cut here---------------start------------->8---
> (defun my/org-bbdb-anniversaries ()
> "It does not work on emacs-23"
> (when (/= 23 emacs-major-version)
> (org-bbdb-anniversaries)
> )
> )
> --8<---------------cut here---------------end--------------->8---
>
> the bbdb record should have the field anniversary:
> --8<---------------cut here---------------start------------->8---
> anniversary: 1960-03-03 custom
> --8<---------------cut here---------------end--------------->8---
>
> Best Regards
>
>
>
> ------------------------------
>
> Message: 27
> Date: Sat, 27 Feb 2021 16:14:19 +0100
> From: Martin Steffen <msteffen@ifi.uio.no>
> To: andrés ramírez <rrandresf@gmail.com>
> Cc: emacs-orgmode <emacs-orgmode@gnu.org>
> Subject: Re: contact management in emacs
> Message-ID: <8635xhee5w.fsf@login.ifi.uio.no>
> Content-Type: text/plain
>
> >>>>> "Eric" == Eric S Fraga <e.fraga@ucl.ac.uk> writes:
>
> Eric> How do you get these to appear? Or is the "could" a wish?
>
> It's ``automatic''. The entry of the person needs a field "anniversary",
> if that's filled with a date in yyyy-mm-dd format, it's included
> (perhaps one has to set a variable like ``show-bbdb-anniversaries''
> and/or load a corresponding elisp-addition.)
>
>
> Martin
>
>
>
>
> Eric> thank you, eric -- : Eric S Fraga via Emacs 28.0.50, Org
> Eric> release_9.4.4-231-gf46925
>
>
>
>
> ------------------------------
>
> Message: 28
> Date: Sat, 27 Feb 2021 06:53:57 -1000
> From: Bob Newell <bobnewell@bobnewell.net>
> To: "emacs-orgmode" <emacs-orgmode@gnu.org>
> Subject: Re: contact management in emacs
> Message-ID: <s6jv9ad1mfu.fsf@emailmessageidheader.nil>
> Content-Type: text/plain
>
> I've used BBDB for years, and have tried org-contact, but it
> didn't seem to scale to the now rather large size of my BBDB
> database.
>
> I've looked at migrating to EBDB but as I have many custom
> functions I haven't yet made the move.
>
> BBDB can do amazing things. I've mentioned some of them
> before. Of course org links are supported, and in conjunction
> with the 'gnorb' package, Gnus email can be associated with
> BBDB entries in interesting ways.
>
> I use BBDB to easily maintain a slew of mailing lists. I also
> have custom functions to set the input language mode for those
> with whom I correspond in non-English languages. I even use
> BBDB to initiate phone calls when I'm on my desktop computer.
>
> I hadn't thought to put BBDB under version control but that
> would be very easy.
>
> However you don't need to get fancy right away. All the basics
> are there. Like many things Emacs, it does take time to get
> things set up the way you wish, but that time is well repaid
> down the road a little.
>
> --
> Bob Newell
> Honolulu, Hawai`i
>
> - Via GNU/Linux/Emacs/Gnus/BBDB
>
>
>
> End of Emacs-orgmode Digest, Vol 180, Issue 30
> **********************************************
>
[-- Attachment #2: Type: text/html, Size: 59355 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: content management in emacs
2021-02-27 18:57 ` content management in emacs Ian Garmaise
2021-02-27 19:16 ` Martin Steffen
@ 2021-02-28 10:39 ` Eric S Fraga
2021-03-07 22:31 ` Jean Louis
2021-03-07 22:38 ` Jean Louis
3 siblings, 0 replies; 9+ messages in thread
From: Eric S Fraga @ 2021-02-28 10:39 UTC (permalink / raw)
To: Ian Garmaise; +Cc: emacs-orgmode
On Saturday, 27 Feb 2021 at 13:57, Ian Garmaise wrote:
> How do you send mail to mailing lists with BBDB?
If the mailing list has a specific address, just create an entry in bbdb
for that list. If the mailing list is a collection of individuals in
your bbdb, you can add a mail-alias entry to each member of the mailing
list with the name for that list.
I use the latter all the time for small research and study groups at
work.
--
: Eric S Fraga via Emacs 28.0.50, Org release_9.4.4-231-gf46925
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: content management in emacs
2021-02-27 19:16 ` Martin Steffen
2021-02-27 20:11 ` Juan Manuel Macías
@ 2021-03-01 5:17 ` Bob Newell
1 sibling, 0 replies; 9+ messages in thread
From: Bob Newell @ 2021-03-01 5:17 UTC (permalink / raw)
To: Martin Steffen; +Cc: emacs-orgmode
Martin Steffen <msteffen@ifi.uio.no> writes:
> For phoning, I am not sure. I think there is (or was) a functionality to
> initiate a call (probably with skype or ekiga or some such) but I never
> used that.
There is bbdb-dial, and I have it set up to call a function
which places a call through Google Hangouts. Of course Google
is deleting that feature so I will have to figure out how to
make it use Google Voice.
Admittedly it's an unnecessary feature but I just have fun
making calls with Emacs instead of fishing around for my cell
phone.
--
Bob Newell
Honolulu, Hawai`i
- Via GNU/Linux/Emacs/Gnus/BBDB
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: content management in emacs
2021-02-27 18:57 ` content management in emacs Ian Garmaise
2021-02-27 19:16 ` Martin Steffen
2021-02-28 10:39 ` Eric S Fraga
@ 2021-03-07 22:31 ` Jean Louis
2021-03-07 22:38 ` Jean Louis
3 siblings, 0 replies; 9+ messages in thread
From: Jean Louis @ 2021-03-07 22:31 UTC (permalink / raw)
To: Ian Garmaise; +Cc: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 765 bytes --]
* Ian Garmaise <ian.g@phorixsol.com> [2021-02-27 21:59]:
> Hi Bob,
>
> How do you send mail to mailing lists with BBDB? Do you use a templating
> tool? Also, how do you start a phone call?
Phone call may be started by using Android/Replicant/LineageOS devices
and Termux tools' https://termux.com command: `termux-telephony-call`
I am adding some of functions I am using, but cannot help in polishing
the package for you. If you need some more functions from here, I will
send you.
You can then send termux command `termux-telephony-call` and initiate
the call on Android/Replicant/LineageOS devices.
For sending SMS I am heavily using KDEConnect, but you may use termux
to send SMS by loading older library (ask me), or by using ShellMS
application.
Jean
[-- Attachment #2: termux.el --]
[-- Type: text/plain, Size: 10601 bytes --]
;;; termux.el --- Termux functions. -*- lexical-binding: t; -*-
;; Copyright (C) 2016-2021 by Jean Louis
;; Author: Jean Louis <bugs@gnu.support>
;; Version: 0.1
;; Package-Requires: (rcd-utilities rcd-cf rcd-db-init rcd-db time-date)
;; Keywords:
;; URL: https://gnu.support/gnu-emacs/packages/termux-el.html
;; This file is not part of GNU Emacs.
;; This program is free software: you can redistribute it and/or
;; modify it under the terms of the GNU General Public License as
;; published by the Free Software Foundation, either version 3 of the
;; License, or (at your option) any later version.
;;
;; This program is distributed in the hope that it will be useful, but
;; WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
;; General Public License for more details.
;;
;; You should have received a copy of the GNU General Public License
;; along with this program. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;; These are the Termux utilities for GNU Emacs Lisp
;;
;; RCD is acronym for Reach, Connect, Deliver, my personal
;; principle and formula for Wealth.
;;; Change Log:
;;; Code:
(require 'rcd-db-init)
(require 'rcd-db)
(require 'rcd-utilities)
(require 'subr-x)
(require 'time-date)
(defcustom termux-ip "192.168.43.1" "IP Address of Replicant system" :type 'string :group 'Termux)
(setq termux-ip "192.168.42.129")
;;(setq termux-ip "192.168.43.1")
(defvar termux-ssh-command "ssh")
(defvar termux-ssh-port "8022")
(defvar termux-bin-directory "/data/data/com.termux/files/usr/bin/")
;;;; END OF SETUP
(defun termux/send-command (command)
"Sends command to connected Replicant device and returns the output string"
(let* ((command (concat termux-ssh-command " -p " termux-ssh-port " " termux-ip " \"" command "\""))
(output (shell-command-to-string command))
(output (string-trim output)))
output))
(defun termux/error (error)
"Messages error"
(message error))
(defun termux/escape-double-quotes (s)
"Escapes double quotes"
(replace-regexp-in-string "\"" "\\\\\"" s))
(defun termux/escape-single-quotes (s)
"Escapes single quotes"
(replace-regexp-in-string "'" "\'" s))
(defun termux/escape-quotes (s)
"Escapes double and single quotes"
(let* ((s (termux/escape-double-quotes s)))
;;(s (termux/escape-single-quotes s)))
s))
(defun termux/commands ()
"Returns the list of all available termux commands and run the command if available."
(interactive)
(let* ((command (concat "cd " termux-bin-directory " && ls termux*"))
(commands (termux/send-command command))
(commands (split-string commands "\n"))
(commands (append commands '("insert-location")))
(command (completing-read "Termux commands: " commands))
(command (intern (concat "termux/" command))))
(if (functionp command)
(funcall command)
(message (concat "Command " (symbol-name command) " does not exist")))))
(defun termux/termux-location ()
(let* ((command "termux-location")
(result (termux/send-command command))
(parsed (json-parse-string result)))
(if (gethash "longitude" parsed)
(let* ((latitude (number-to-string (gethash "latitude" parsed)))
(longitude (number-to-string (gethash "longitude" parsed)))
(location (concat latitude "," longitude)))
location)
(termux/error "Could not get location"))))
(defun termux/termux-location-insert ()
"Inserts current location in the buffer"
(interactive)
(let ((location (termux/termux-location)))
(insert location)))
(defun termux/termux-clipboard-get ()
"Returns the Replicant clipboard value"
(let* ((command "termux-clipboard-get")
(result (termux/send-command command)))
result))
(defun termux/termux-clipboard-get-insert ()
"Inserts the Replicant clipboard value"
(interactive)
(let ((clipboard (termux/termux-clipboard-get)))
(insert clipboard)))
(defun termux/termux-clipboard-set (value)
"Sets the Replicant clipboard value"
(interactive "MSet clipboard to: ")
(let* ((value (termux/escape-double-quotes value))
(command (concat "termux-clipboard-set \"" value "\"")))
(termux/send-command command)))
(defun termux/termux-wifi-enable (boolean) ;; TODO
"Enable or disable Wi-Fi on Replicant"
(interactive "MEnable Wi-Fi (T for true, F or else for false): ")
(let* ((boolean (if (string-match "t" (downcase boolean)) "true" "false"))
(command (concat "termux-wifi-enable \"" boolean "\"")))
(termux/send-command command)))
(defun termux/termux-tts-speak (text)
"Speaks by using termux"
(interactive "MText to speak: ")
(let* ((text (termux/escape-quotes text))
(command (concat "termux-tts-speak \"" text "\"")))
(termux/send-command command)))
(defun termux/termux-vibrate ()
"Vibrate Replicant device"
(interactive)
(let* ((command "termux-vibrate"))
(termux/send-command command)))
;; (defun termux-sms-send (number text)
;; "Sends SMS message by using termux"
;; (interactive "MNumber: \nMText: ")
;; (let* ((text (termux/escape-double-quotes text))
;; (command (concat "termux-sms-send -n \"" number "\" \"" text "\"")))
;; (termux/send-command command)))
(defun termux-sms-send (number text)
"Send SMS message by using ShellMS application"
(let* ((text (termux/escape-quotes text))
(command (format "am startservice --user 0 -n com.android.shellms/.sendSMS -e contact %s -e msg \\\"%s\\\"" number text)))
(termux/send-command command)))
;; (termux-sms-send "+123" sms)
;; (termux-sms-send "+123" "Hello")
;; (termux-sms-send "+123" "Hello thank you, but I do not have this number registered, what is your name?")
(defun termux-import-sms-list ()
(interactive)
(let* ((command "termux-sms-list -t inbox -l 500")
(list (termux/send-command command))
(list (json-parse-string list))
(remainder-file (concat (getenv "TMPDIR") "SMS-import-" (rcd-timestamp) ".el"))
(_ (data-to-file list remainder-file))
(how-many (length list)))
(dotimes (n how-many)
(let ((sms (elt list n)))
(cf-sms-insert sms)))))
;; (termux-import-sms-list)
(defun cf-sms-handle (sms)
"Returns list after reading the `sms' hash"
(let* ((type (gethash "type" sms))
(status (cf-sms-status type))
(number (gethash "number" sms))
(date-received (gethash "received" sms))
(body (gethash "body" sms)))
(list status number date-received body)))
(defun cf-sms-status (status)
(cond ((string= status "inbox") 2)
(t (error (concat "Cannot find SMS type: " status)))))
(defun cf-sms-insert (sms)
"Inserts the SMS hash into the database"
(let ((exists (cf-sms-imported-exists sms)))
(if exists (message-any sms)
(let* ((sms (cf-sms-handle sms))
(status (elt sms 0))
(number (elt sms 1))
(date-received (elt sms 2))
(date-received (cf-sms-repair-date date-received))
(body (elt sms 3))
(body (sql-escape-string body))
(id (cf-contact-by-phone-1 number))
(sql (format "INSERT INTO sms (sms_datecreated, sms_contacts, sms_smsstatus, sms_body, sms_phone) VALUES ('%s', %s, %s, %s, '%s') RETURNING sms_id" date-received id status body number)))
(if id (rcd-sql-first sql *cf*)
(message (format "SMS not entered: %s" (prin1-to-string sms))))))))
(defun cf-sms-imported-exists (sms)
(let* ((sms (cf-sms-handle sms))
(status (elt sms 0))
(number (elt sms 1))
(date-received (elt sms 2))
(date-received (cf-sms-repair-date date-received))
(body (elt sms 3))
(body (sql-escape-string body))
(id (cf-contact-by-phone-1 number))
(sql (format "SELECT * FROM sms WHERE sms_datecreated = '%s' AND sms_contacts = %s AND sms_smsstatus = %s AND sms_body = %s AND sms_phone = '%s'" date-received id status body number)))
(if id
(let ((ids (rcd-sql-list sql *cf*)))
(if ids ids nil))
(message (format "SMS did not find ID: %s" (prin1-to-string sms))))))
(defun cf-sms-repair-date (date)
"Repairs the date give by `termux-sms-list' function"
(let* ((time (decoded-time-add (parse-time-string date) '(nil nil nil nil nil nil nil nil nil)))
(year (decoded-time-year time))
(month (decoded-time-month time))
(day (decoded-time-day time))
(hour (decoded-time-hour time))
(minute (decoded-time-minute time))
(second (decoded-time-second time))
(date-time (format "%04.f-%02.f-%02.f %02.f:%02.f:%02.f" year month day hour minute second)))
date-time))
;; (defun termux-sms-list ()
;; (interactive)
;; (let* ((command "termux-sms-list -t inbox -l 500")
;; (list (termux/send-command command))
;; (list (json-parse-string list))
;; (how-many (length list)))
;; (dotimes (n how-many)
;; (let ((sms (elt list n)))
;; (cf-sms-insert sms)))))
(defun rcd-kdeconnect-send-sms (number message)
(let* ((status (shell-command
(mapconcat 'identity
(list "kdeconnect-cli" "-d"
;; "73fc592ea61a3a70" ;; Airtel
"c47e5d958b455603" ;; MTN
"--destination" number
"--send-sms" (shell-quote-argument message))
" "))))
status))
(defvar rcd-prefixes-uganda-airtel-mobile '(700 701 702 703 704 705 706
710 711 712 713 714 715 716 717 718 719
750 751 752 753 754 755 756 757 758 759))
(defvar rcd-prefixes-uganda-mtn-mobile '(770 771 772 773 774 775 776 777 778 779
780 781 782 783 784 785 786 787 788 789))
(defun rcd-sql-phone-national-prefix-or (country-prefix prefixes)
(let* ((country-prefix (if (numberp country-prefix)
(number-to-string country-prefix)
country-prefix))
(prefixes (mapcar (lambda (n) (single-quote (concat country-prefix (number-to-string n)))) prefixes))
(prefixes (string-join prefixes ", ")))
prefixes))
(defun rcd-sql-phone-recent-people-by-mobile-prefix (prefixes &optional how-many)
(let* ((how-many (or how-many 200))
(sql (format "SELECT people_id, get_full_contacts_name(people_id) FROM people WHERE (substring(people_officephone, 2, 6) IN (%s) OR substring(people_mobilephone, 2, 6) IN (%s) OR substring(people_homephone, 2, 6) IN (%s) OR substring(people_otherphone, 2, 6) IN (%s) OR substring(people_fax, 2, 6) IN (%s)) ORDER BY people_id DESC LIMIT %s" prefixes prefixes prefixes prefixes prefixes how-many)))
sql))
(defun cf-tabulated-people-recent-by-airtel-mobile ()
(interactive)
(let* ((prefixes (rcd-sql-phone-national-prefix-or 256 rcd-prefixes-uganda-airtel-mobile))
(sql (rcd-sql-phone-recent-people-by-mobile-prefix prefixes)))
(rcd-db-sql-report-two "Recent people with UG Airtel numbers" sql [("ID" 8) ("Person" 80)] "people" nil)))
(provide 'termux)
;;; termux.el ends here
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: content management in emacs
2021-02-27 18:57 ` content management in emacs Ian Garmaise
` (2 preceding siblings ...)
2021-03-07 22:31 ` Jean Louis
@ 2021-03-07 22:38 ` Jean Louis
3 siblings, 0 replies; 9+ messages in thread
From: Jean Louis @ 2021-03-07 22:38 UTC (permalink / raw)
To: Ian Garmaise; +Cc: emacs-orgmode
* Ian Garmaise <ian.g@phorixsol.com> [2021-02-27 21:59]:
> Hi Bob,
>
> How do you send mail to mailing lists with BBDB?
I have complete mailing list system in Emacs that uses the
database. Sending to a list without recording who received which email
is leading sooner or later to nonsensical situations that ruin
relations with people. When somebody wish to setup email, and has
patience, I will help with installation until it starts working and
until the user becomes able to create and send first email series.
One has to track which person received which email at what time.
Imagine the timeline of people being entered into any kind of a
database, in January there are 30 people, they need to receive maybe
2-3 emails named A, B, and C each week, but in February there are
other 22 people who need to receive 2-3 emails A, B, C and the first
30 people from January have to receieve emails D, E, F, G in
February.
I am including here the dump of the `emails` table in the database and
if other tables are required, I will send it.
The `mailings` table below is tracking which person received which
email at what time. Only by defining the periods between emails and
tracking emails in the database one can make a series of follow-up
emails that are logical and useful in sales or relation building.
We sell for hundreds of thousands of dollars by using this
system. There is no need for remote databases or keeping contact lists
on remote servers.
Emails are dispatched to the local computer's queue, and then
forwarded to remote SMTP server. Currently I am using `msmtp` to
forward bulk emails.
Jean
--
-- PostgreSQL database dump
--
-- Dumped from database version 13.0
-- Dumped by pg_dump version 13.0
SET statement_timeout = 0;
SET lock_timeout = 0;
SET idle_in_transaction_session_timeout = 0;
SET client_encoding = 'UTF8';
SET standard_conforming_strings = on;
SELECT pg_catalog.set_config('search_path', '', false);
SET check_function_bodies = false;
SET xmloption = content;
SET client_min_messages = warning;
SET row_security = off;
SET default_tablespace = '';
SET default_table_access_method = heap;
--
-- Name: emails; Type: TABLE; Schema: public; Owner: maddox
--
CREATE TABLE public.emails (
emails_id integer NOT NULL,
emails_datecreated timestamp without time zone DEFAULT now(),
emails_datemodified timestamp without time zone,
emails_date timestamp with time zone,
emails_time time without time zone,
emails_account integer,
emails_contact integer,
emails_opportunity integer,
emails_assignedto integer,
emails_subject text NOT NULL,
emails_body text,
emails_sent boolean DEFAULT true,
emails_templates integer NOT NULL,
emails_mailinglist integer,
emails_priority integer DEFAULT 1000 NOT NULL,
emails_emailtypes integer DEFAULT 1 NOT NULL,
emails_delay text DEFAULT 7 NOT NULL,
emails_intervals integer DEFAULT 2 NOT NULL,
emails_languages integer DEFAULT 1 NOT NULL,
emails_periodic boolean DEFAULT false,
emails_blastnow boolean DEFAULT false NOT NULL,
emails_blastonce boolean DEFAULT false NOT NULL,
emails_maxdate timestamp with time zone,
emails_maxtime text,
emails_timezones integer,
emails_weekdays integer,
emails_includecountries integer,
emails_excludecountries integer,
emails_pages integer,
emails_emailformats integer DEFAULT 1 NOT NULL,
emails_marks integer,
emails_city text,
emails_countries integer,
emails_excludemarks integer
);
ALTER TABLE public.emails OWNER TO maddox;
--
-- Name: TABLE emails; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON TABLE public.emails IS 'E-mails';
--
-- Name: COLUMN emails.emails_id; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_id IS 'ID';
--
-- Name: COLUMN emails.emails_datecreated; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_datecreated IS 'Date created';
--
-- Name: COLUMN emails.emails_datemodified; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_datemodified IS 'Date modified';
--
-- Name: COLUMN emails.emails_date; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_date IS 'Date';
--
-- Name: COLUMN emails.emails_time; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_time IS 'Time';
--
-- Name: COLUMN emails.emails_account; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_account IS 'Account';
--
-- Name: COLUMN emails.emails_contact; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_contact IS 'Contact';
--
-- Name: COLUMN emails.emails_opportunity; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_opportunity IS 'Opportunity';
--
-- Name: COLUMN emails.emails_assignedto; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_assignedto IS 'Assigned to';
--
-- Name: COLUMN emails.emails_subject; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_subject IS 'Subject';
--
-- Name: COLUMN emails.emails_body; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_body IS 'Body';
--
-- Name: COLUMN emails.emails_sent; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_sent IS 'Sent';
--
-- Name: COLUMN emails.emails_templates; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_templates IS 'Template';
--
-- Name: COLUMN emails.emails_mailinglist; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_mailinglist IS 'Mailing List';
--
-- Name: COLUMN emails.emails_priority; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_priority IS 'Priority';
--
-- Name: COLUMN emails.emails_emailtypes; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_emailtypes IS 'Type';
--
-- Name: COLUMN emails.emails_delay; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_delay IS 'Delay';
--
-- Name: COLUMN emails.emails_intervals; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_intervals IS 'Interval';
--
-- Name: COLUMN emails.emails_languages; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_languages IS 'Language';
--
-- Name: COLUMN emails.emails_periodic; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_periodic IS 'Periodic';
--
-- Name: COLUMN emails.emails_blastnow; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_blastnow IS 'Blast now';
--
-- Name: COLUMN emails.emails_blastonce; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_blastonce IS 'Blast once';
--
-- Name: COLUMN emails.emails_maxdate; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_maxdate IS 'Max date';
--
-- Name: COLUMN emails.emails_maxtime; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_maxtime IS 'Max time';
--
-- Name: COLUMN emails.emails_timezones; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_timezones IS 'Time zone';
--
-- Name: COLUMN emails.emails_weekdays; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_weekdays IS 'Weekday';
--
-- Name: COLUMN emails.emails_includecountries; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_includecountries IS 'Include countries';
--
-- Name: COLUMN emails.emails_excludecountries; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_excludecountries IS 'Exclude countries';
--
-- Name: COLUMN emails.emails_pages; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_pages IS 'Page to send';
--
-- Name: COLUMN emails.emails_emailformats; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_emailformats IS 'Format';
--
-- Name: COLUMN emails.emails_marks; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_marks IS 'Marked by';
--
-- Name: COLUMN emails.emails_city; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_city IS 'City';
--
-- Name: COLUMN emails.emails_countries; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_countries IS 'Country';
--
-- Name: COLUMN emails.emails_excludemarks; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.emails.emails_excludemarks IS 'Exclude marked as';
--
-- Name: emails_emails_id_seq; Type: SEQUENCE; Schema: public; Owner: maddox
--
CREATE SEQUENCE public.emails_emails_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER TABLE public.emails_emails_id_seq OWNER TO maddox;
--
-- Name: emails_emails_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: maddox
--
ALTER SEQUENCE public.emails_emails_id_seq OWNED BY public.emails.emails_id;
--
-- Name: emails emails_id; Type: DEFAULT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails ALTER COLUMN emails_id SET DEFAULT nextval('public.emails_emails_id_seq'::regclass);
--
-- Name: emails emails_pkey; Type: CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_pkey PRIMARY KEY (emails_id);
--
-- Name: emails emails_emails_account_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_account_fkey FOREIGN KEY (emails_account) REFERENCES public.accounts(accounts_id);
--
-- Name: emails emails_emails_assignedto_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_assignedto_fkey FOREIGN KEY (emails_assignedto) REFERENCES public.people(people_id);
--
-- Name: emails emails_emails_contact_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_contact_fkey FOREIGN KEY (emails_contact) REFERENCES public.people(people_id);
--
-- Name: emails emails_emails_countries_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_countries_fkey FOREIGN KEY (emails_countries) REFERENCES public.countries(countries_id);
--
-- Name: emails emails_emails_emailformats_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_emailformats_fkey FOREIGN KEY (emails_emailformats) REFERENCES public.emailformats(emailformats_id);
--
-- Name: emails emails_emails_emailtypes_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_emailtypes_fkey FOREIGN KEY (emails_emailtypes) REFERENCES public.emailtypes(emailtypes_id);
--
-- Name: emails emails_emails_excludecountries_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_excludecountries_fkey FOREIGN KEY (emails_excludecountries) REFERENCES public.countrylists(countrylists_id);
--
-- Name: emails emails_emails_excludemarks_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_excludemarks_fkey FOREIGN KEY (emails_excludemarks) REFERENCES public.marks(marks_id);
--
-- Name: emails emails_emails_includecountries_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_includecountries_fkey FOREIGN KEY (emails_includecountries) REFERENCES public.countrylists(countrylists_id);
--
-- Name: emails emails_emails_intervals_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_intervals_fkey FOREIGN KEY (emails_intervals) REFERENCES public.intervals(intervals_id);
--
-- Name: emails emails_emails_languages_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_languages_fkey FOREIGN KEY (emails_languages) REFERENCES public.languages(languages_id);
--
-- Name: emails emails_emails_mailinglist_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_mailinglist_fkey FOREIGN KEY (emails_mailinglist) REFERENCES public.accounts(accounts_id);
--
-- Name: emails emails_emails_marks_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_marks_fkey FOREIGN KEY (emails_marks) REFERENCES public.marks(marks_id);
--
-- Name: emails emails_emails_opportunity_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_opportunity_fkey FOREIGN KEY (emails_opportunity) REFERENCES public.opportunities(opportunities_id);
--
-- Name: emails emails_emails_pages_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_pages_fkey FOREIGN KEY (emails_pages) REFERENCES public.pages(pages_id);
--
-- Name: emails emails_emails_templates_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_templates_fkey FOREIGN KEY (emails_templates) REFERENCES public.templates(templates_id);
--
-- Name: emails emails_emails_timezones_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_timezones_fkey FOREIGN KEY (emails_timezones) REFERENCES public.timezones(timezones_id);
--
-- Name: emails emails_emails_weekdays_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.emails
ADD CONSTRAINT emails_emails_weekdays_fkey FOREIGN KEY (emails_weekdays) REFERENCES public.weekdays(weekdays_id);
--
-- PostgreSQL database dump complete
--
--
-- PostgreSQL database dump
--
-- Dumped from database version 13.0
-- Dumped by pg_dump version 13.0
SET statement_timeout = 0;
SET lock_timeout = 0;
SET idle_in_transaction_session_timeout = 0;
SET client_encoding = 'UTF8';
SET standard_conforming_strings = on;
SELECT pg_catalog.set_config('search_path', '', false);
SET check_function_bodies = false;
SET xmloption = content;
SET client_min_messages = warning;
SET row_security = off;
SET default_tablespace = '';
SET default_table_access_method = heap;
--
-- Name: mailings; Type: TABLE; Schema: public; Owner: maddox
--
CREATE TABLE public.mailings (
mailings_id integer NOT NULL,
mailings_datecreated timestamp without time zone DEFAULT now() NOT NULL,
mailings_usercreated text DEFAULT "current_user"() NOT NULL,
mailings_contacts integer NOT NULL,
mailings_mailingtypes integer DEFAULT 1 NOT NULL,
mailings_fromcompany integer NOT NULL,
mailings_subject text NOT NULL,
mailings_description text,
mailings_emails integer,
mailings_mailingstatuses integer
);
ALTER TABLE public.mailings OWNER TO maddox;
--
-- Name: TABLE mailings; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON TABLE public.mailings IS 'Mailings';
--
-- Name: COLUMN mailings.mailings_id; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.mailings.mailings_id IS 'ID';
--
-- Name: COLUMN mailings.mailings_datecreated; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.mailings.mailings_datecreated IS 'Date created';
--
-- Name: COLUMN mailings.mailings_usercreated; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.mailings.mailings_usercreated IS 'User created';
--
-- Name: COLUMN mailings.mailings_contacts; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.mailings.mailings_contacts IS 'Contact';
--
-- Name: COLUMN mailings.mailings_mailingtypes; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.mailings.mailings_mailingtypes IS 'Mailing Type';
--
-- Name: COLUMN mailings.mailings_fromcompany; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.mailings.mailings_fromcompany IS 'Sender';
--
-- Name: COLUMN mailings.mailings_subject; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.mailings.mailings_subject IS 'Subject';
--
-- Name: COLUMN mailings.mailings_description; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.mailings.mailings_description IS 'Description';
--
-- Name: COLUMN mailings.mailings_emails; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.mailings.mailings_emails IS 'E-mail ID';
--
-- Name: COLUMN mailings.mailings_mailingstatuses; Type: COMMENT; Schema: public; Owner: maddox
--
COMMENT ON COLUMN public.mailings.mailings_mailingstatuses IS 'Status';
--
-- Name: mailings_mailings_id_seq; Type: SEQUENCE; Schema: public; Owner: maddox
--
CREATE SEQUENCE public.mailings_mailings_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER TABLE public.mailings_mailings_id_seq OWNER TO maddox;
--
-- Name: mailings_mailings_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: maddox
--
ALTER SEQUENCE public.mailings_mailings_id_seq OWNED BY public.mailings.mailings_id;
--
-- Name: mailings mailings_id; Type: DEFAULT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.mailings ALTER COLUMN mailings_id SET DEFAULT nextval('public.mailings_mailings_id_seq'::regclass);
--
-- Name: mailings mailings_pkey; Type: CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.mailings
ADD CONSTRAINT mailings_pkey PRIMARY KEY (mailings_id);
--
-- Name: mailings mailings_mailings_contacts_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.mailings
ADD CONSTRAINT mailings_mailings_contacts_fkey FOREIGN KEY (mailings_contacts) REFERENCES public.people(people_id);
--
-- Name: mailings mailings_mailings_emails_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.mailings
ADD CONSTRAINT mailings_mailings_emails_fkey FOREIGN KEY (mailings_emails) REFERENCES public.emails(emails_id);
--
-- Name: mailings mailings_mailings_fromcompany_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.mailings
ADD CONSTRAINT mailings_mailings_fromcompany_fkey FOREIGN KEY (mailings_fromcompany) REFERENCES public.accounts(accounts_id);
--
-- Name: mailings mailings_mailings_mailingstatuses_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.mailings
ADD CONSTRAINT mailings_mailings_mailingstatuses_fkey FOREIGN KEY (mailings_mailingstatuses) REFERENCES public.mailingstatuses(mailingstatuses_id);
--
-- Name: mailings mailings_mailings_mailingtypes_fkey; Type: FK CONSTRAINT; Schema: public; Owner: maddox
--
ALTER TABLE ONLY public.mailings
ADD CONSTRAINT mailings_mailings_mailingtypes_fkey FOREIGN KEY (mailings_mailingtypes) REFERENCES public.mailingtypes(mailingtypes_id);
--
-- Name: TABLE mailings; Type: ACL; Schema: public; Owner: maddox
--
GRANT ALL ON TABLE public.mailings TO PUBLIC;
--
-- PostgreSQL database dump complete
--
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: contact management in emacs
2021-02-27 20:52 ` contact " dalanicolai
@ 2021-03-07 22:51 ` Jean Louis
0 siblings, 0 replies; 9+ messages in thread
From: Jean Louis @ 2021-03-07 22:51 UTC (permalink / raw)
To: dalanicolai; +Cc: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 2684 bytes --]
* dalanicolai <dalanicolai@gmail.com> [2021-02-27 23:53]:
> I think all packages fulfill your requirements. So I would say it depends
> on how many contacts you are managing. I have some experience with
> org-contacts, and I find it very convenient and straightforward. It is also
> very convenient to just use org-mode, i.e. a plain text file, for your
> contacts.
That may be convenient for friends or family, but is not a good idea
if such a contact database is to enlarge due to marketing actions.
People who collect leads and manage relations with many other people
must have straight way to manage contacts, and similar to well known
CRM systems such as SugarCRM or others. In fact contact management
could be managed by external program and database accessed through
Emacs. Though I do both with Emacs. And I like to access database from
shell as I do not use only Emacs as editor. As the database is
liberated from editor it allows access through any software or
programming language.
> Every contact is a headline and you can add any kind of property
> or tag etc. you want. Also anniversaries get added to the Agenda. You can
> very easily jump to the right contact, using imenu or swoop/swiper (I use
> `SPC j i ` in Spacemacs. So if you have less than say 300 contacts (I have
> really no clue about the number of contacts that will still work smoothly),
> then depending on how die-hard you are, I would recommend to start with
> org-contacs.
More important is how fast are contacts coming into the database. If
there are just 100 per year, then that will work well.
But marketing action of 23 hours have provided me like 1700 contacts,
so there would be no way that I ever keep up with text or hand
work. That requires automated insertion of contacts into the database,
and I use local database. Online lead capture is sent PGP encrypted by
email and emails are automatically processed and leads entered into
the local database. Placing contacts online is insecure IMHO, no
matter what is advertised about it.
> You can use org-vcard to import contacts, and org-vcard claims to
> support exports too but I did not test that yet. Anyway, I think
> you won't loose much time with setting up org-contacts and from then
> you can slowly check out and study the other options.
I am attaching `rcd-vcard.el` that uses PostgreSQL database and my
schemas to export vCards that work nicely with
Android/LineageOS/Replicant devices. Package alone will not
work. Functions may be useful for some people to modify them as they
wish. If somebody wish to really install my system, I will be helpful
in private chat or email and guide person until it becomes functional.
Jean
[-- Attachment #2: rcd-vcard.el --]
[-- Type: text/plain, Size: 9384 bytes --]
;;; rcd-vcard.el --- RCD vCard functions -*- lexical-binding: t; -*-
;; Copyright (C) 2016-2021 by Jean Louis
;; Author: Jean Louis <bugs@gnu.support>
;; Version: 0.1
;; Package-Requires: (rcd-utilities rcd-db-init rcd-db rcd-cf)
;; Keywords:
;; URL: https://gnu.support/gnu-emacs/packages/rcd-vcard.html
;; This file is not part of GNU Emacs.
;; This program is free software: you can redistribute it and/or
;; modify it under the terms of the GNU General Public License as
;; published by the Free Software Foundation, either version 3 of the
;; License, or (at your option) any later version.
;;
;; This program is distributed in the hope that it will be useful, but
;; WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
;; General Public License for more details.
;;
;; You should have received a copy of the GNU General Public License
;; along with this program. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;; These are the RCD vCard functions
;;
;; RCD is acronym for Reach, Connect, Deliver, my personal
;; principle and formula for Wealth.
;;; Change Log:
;;; Code:
(require 'rcd-utilities)
(require 'rcd-db-init)
(require 'rcd-db)
(require 'rcd-cf)
(defvar *rcd-vcard-version* "2.1")
(defvar *rcd-vcard-output* "~/tmp/rcd-vcards/")
(defun rcd-vcard-jabber (xmpp)
(if (rcd-string-not-empty-p xmpp)
(format "X-JABBER:%s\nX-JABBER;WORK:%s\n" xmpp xmpp)
""))
(defun rcd-vcard-tel (tel &optional type)
(if (rcd-string-not-empty-p tel)
(let* ((type (or type "CELL"))
(type (upcase type)))
(format "TEL;%s:%s\n" type tel))
""))
(defun rcd-vcard-address (address1 city1 zip1 state1 country1 address2 city2 zip2 state2 country2)
(with-output-to-string
(princ "ADR;DOM;HOME;:")
(princ city1)
(princ ";")
(princ country1)
(princ "\n"))) ;; TODO
(defun rcd-vcard-phones (office mobile home other fax &optional other-2 other-3 other-4)
(with-output-to-string
(when office
(princ (rcd-vcard-tel office "WORK")))
(when mobile
(princ (rcd-vcard-tel mobile "CELL")))
(when home
(princ (rcd-vcard-tel home "HOME")))
(when other
(princ (rcd-vcard-tel other "OTHER")))
(when fax
(princ (rcd-vcard-tel fax "FAX")))
(when other-2
(princ (rcd-vcard-tel other-2 "OTHER")))
(when other-3
(princ (rcd-vcard-tel other-3 "OTHER")))
(when other-3
(princ (rcd-vcard-tel other-3 "OTHER")))))
(defun rcd-vcard-title (title)
(if (rcd-string-not-empty-p title)
(format "TITLE:%s\n" title)
""))
(defun rcd-vcard-organization (org &optional unit)
(if (rcd-string-not-empty-p org)
(let ((unit (or unit "")))
(format "ORG:%s;%s\n" org unit))
""))
;; (defun rcd-vcard-note (note)
;; (if (rcd-string-not-empty-p note)
;; (format "NOTE:ENCODING=BASE64;:%s\n" (base64-encode-string note))
;; ""))
(defun rcd-vcard-note (id note)
(with-output-to-string
;; (princ (format "NOTE;ENCODING=BIT8;:Contact ID %s; " id))
(princ (format "NOTE:Contact ID %s" id))
(if (rcd-string-not-empty-p note)
(princ (format "%s\n" "")) ;; place note instead of ""
"")))
(defun rcd-vcard-begin ()
(format "BEGIN:VCARD\nVERSION:%s\n" *rcd-vcard-version*))
(defun rcd-vcard-end ()
(format "END:VCARD\n"))
(defun rcd-vcard-email (email &optional type)
(if (rcd-string-not-empty-p email)
(let* ((type (or type "HOME"))
(type (upcase type)))
(format "EMAIL;%s:%s\n" type email))
""))
(defun rcd-vcard-url (url)
(if (rcd-string-not-empty-p url)
(format "URL:%s\n" url)
""))
(defun rcd-vcard-birthday (bday)
(if (rcd-string-not-empty-p bday)
(format "BDAY:%s\n" bday)
""))
(defun rcd-vcard-formatted-name (fn)
(if (rcd-string-not-empty-p fn)
(format "FN:%s\n" fn)
""))
(defun rcd-vcard-name (last &optional first middle prefix suffix)
(if (rcd-string-not-empty-p last)
(let ((first (or first ""))
(middle (or middle ""))
(prefix (or prefix ""))
(suffix (or suffix "")))
(format "N;CHARSET=UTF-8:%s;%s;%s;%s;%s;\n" last first middle prefix suffix))
""))
(defun cf-contact-geo-location (id)
(let* ((sql (format "SELECT locations_latitude, locations_longitude FROM locations WHERE locations_contacts = %s" id))
(geo (car (rcd-sql-list sql *cf*)))
(latitude (car geo))
(longitude (cadr geo)))
(if geo
(format "geo:%s,%s" latitude longitude)
nil)))
(defun rcd-cf-contact-vcard-list (id)
(let* ((hash (rcd-db-table-id-hash-values "people" id *cf*))
(prefix (gethash 'people_prefix hash))
(first (gethash 'people_firstname hash))
(middle (gethash 'people_middlenames hash))
(last (gethash 'people_lastname hash))
(suffix (gethash 'people_suffix hash))
(account (gethash 'people_account1 hash))
(company (gethash 'people_account2 hash))
(member (gethash 'people_account3 hash))
(title (gethash 'people_title hash))
(department (gethash 'people_department hash))
(birthday (gethash 'people_birthdate hash))
(office (gethash 'people_officephone hash))
(mobile (gethash 'people_mobilephone hash))
(home (gethash 'people_homephone hash))
(other (gethash 'people_otherphone hash))
(fax (gethash 'people_fax hash))
(email1 (gethash 'people_email1 hash))
(email2 (gethash 'people_email2 hash))
(email3 (gethash 'people_email3 hash))
(website (gethash 'people_website1 hash))
(blog (gethash 'people_website2 hash))
(address1 (gethash 'people_address1 hash))
(city1 (gethash 'people_city1 hash))
(zip1 (gethash 'people_zip1 hash))
(state1 (gethash 'people_state1 hash))
(country1 (gethash 'people_country1 hash))
(address2 (gethash 'people_address2 hash))
(city2 (gethash 'people_city2 hash))
(zip2 (gethash 'people_zip2 hash))
(state2 (gethash 'people_state2 hash))
(country2 (gethash 'people_country2 hash))
(note (gethash 'people_description hash))
(geo (cf-contact-geo-location id))
(geo (if geo (upcase geo) ""))
(contact (list prefix first middle last suffix account company member title department birthday office mobile home other fax email1 email2 email3 website blog address1 city1 zip1 state1 country1 address2 city2 zip2 state2 country2 note geo)))
(mapcar 'string-blank-nil contact)))
(defun rcd-cf-contact-vcard (id)
(let* ((contact (rcd-cf-contact-vcard-list id))
(full-name (cf-get-full-name id))
(vcard (rcd-vcard-begin))
(prefix (elt contact 0))
(first (elt contact 1))
(middle (elt contact 2))
(last (elt contact 3))
(suffix (elt contact 4))
(n (rcd-vcard-name last first middle prefix suffix))
(vcard (concat vcard n))
(fn (concat prefix " " first " " middle " " last " " suffix))
(fn (replace-regexp-in-string " +" " " fn))
(fn (rcd-vcard-formatted-name fn))
(vcard (concat vcard fn))
(account (elt contact 5))
(company (elt contact 6))
(member (elt contact 7))
(title (elt contact 8))
(department (elt contact 9))
(org (rcd-vcard-organization company department))
(vcard (concat vcard org))
(account-org (rcd-vcard-organization account "Account"))
(vcard (concat vcard account-org))
(member-org (rcd-vcard-organization member "Member"))
(vcard (concat vcard member-org))
(vcard (concat vcard (rcd-vcard-title title)))
(birthday (elt contact 10))
(vcard (concat vcard (rcd-vcard-birthday birthday)))
(office (elt contact 11))
(mobile (elt contact 12))
(home (elt contact 13))
(other (elt contact 14))
(fax (elt contact 15))
(phones (rcd-vcard-phones office mobile home other fax))
(vcard (concat vcard phones))
(email1 (elt contact 16))
(email2 (elt contact 17))
(email3 (elt contact 18))
(vcard (concat vcard (rcd-vcard-email email1)))
(vcard (concat vcard (rcd-vcard-email email2)))
(vcard (concat vcard (rcd-vcard-email email3)))
(website (elt contact 19))
(vcard (concat vcard (rcd-vcard-url website)))
(blog (elt contact 20))
(vcard (concat vcard (rcd-vcard-url blog)))
(address1 (elt contact 21))
(city1 (elt contact 22))
(zip1 (elt contact 23))
(state1 (elt contact 24))
(country1 (elt contact 25))
(address2 (elt contact 26))
(city2 (elt contact 27))
(zip2 (elt contact 28))
(state2 (elt contact 29))
(country2 (elt contact 30))
(address (rcd-vcard-address address1 city1 zip1 state1 country1 address2 city2 zip2 state2 country2))
(vcard (concat vcard address))
(note (elt contact 31))
(note (rcd-vcard-note id note))
(vcard (concat vcard note))
(geo (elt contact 32))
(geo (if geo (concat geo "\n") ""))
(vcard (concat vcard geo))
;;(vcard (concat vcard note))
(vcard (concat vcard (rcd-vcard-end))))
vcard))
(defun rcd-vcard-mobile-1 ()
"Exports all vCards for mobile phone #1"
(interactive)
(make-directory *rcd-vcard-output* t)
(let* ((ids (rcd-sql "SELECT addressbookentries_people FROM addressbookentries" *cf*)))
(string-to-file-force
(with-output-to-string
(dolist (id ids)
(princ (rcd-cf-contact-vcard id))))
(concat *rcd-vcard-output* "rcd-people.vcf"))))
(defun cf-contact-vcard-export (id)
"Export vCard for contact ID"
(let ((vcard (rcd-cf-contact-vcard id))
(file (format "%s%08d.vcf" *rcd-vcard-output* id)))
(string-to-file-force vcard file)
(message (concat "vCard exported to: " file))))
(provide 'rcd-vcard)
;;; rcd-vcard.el ends here
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2021-03-07 22:54 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <mailman.47.1614445226.20994.emacs-orgmode@gnu.org>
2021-02-27 18:57 ` content management in emacs Ian Garmaise
2021-02-27 19:16 ` Martin Steffen
2021-02-27 20:11 ` Juan Manuel Macías
2021-03-01 5:17 ` Bob Newell
2021-02-28 10:39 ` Eric S Fraga
2021-03-07 22:31 ` Jean Louis
2021-03-07 22:38 ` Jean Louis
2021-02-27 20:52 ` contact " dalanicolai
2021-03-07 22:51 ` Jean Louis
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.