emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [O] org-contacts: how to manage contacts; structure of meta data


From: Karl Voit
Subject: Re: [O] org-contacts: how to manage contacts; structure of meta data
Date: Thu, 6 Oct 2011 11:38:26 +0200
User-agent: slrn/0.9.9 (Linux)

* Thorsten <address@hidden> wrote:
> Karl Voit <address@hidden> writes:
>
>> Without describing further attempts, I ended up with following
>> yasnippet[2] template for a new contact:
>
> Do you think that yasnippet is superior to org-capture or is it just a
> casuality that you prefered it to org-capture?

Oh, first I started with org-capture. One week later I started to
use yasnippet. I have to mention that I was using Emacs a decade ago
when I switched to vim. For Org-mode I returned to GNU Emacs. Now I
have to re-orienteer again what is available and how it works :-)

yasnippet is superior to org-capture and it is not :-)

What is missing with yasnippet is a quick capture method which
includes the destination for the new item.

What is great with yasnippet is, that you can define certain input
values that have to be entered. Those values can be re-used. So when
you take a look at my snippet, you recognize $1, $2, ...

And you recognize that $1 and $2 a re-used. I do have to enter $1
only once and it is inserted multiple times - depending on the
occurrence of $1 in the rest.

For the :TYPE: property I let yasnippet ask me, whether it is a
person or a company I am entering now. Handy.

>> ,----
>> | # name : Org-contacts template for a person or a company
>> | # --
>> | ** $1 $2  :$1$2:
>> | :PROPERTIES:
>> | :TYPE: ${3:$$(yas/choose-value '("person" "company"))}
>> | :TITLE:
>> | :EMAIL: $4
>> | :URL:
>> | :MOBILE: 0043/
>> | :HOMEPHONE:
>> | :WORKPHONE:
>> | :PHONE:
>> | :COMPANY:
>> | :STREET:
>> | :POSTALCODE:
>> | :CITY:
>> | :COUNTRY: Österreich
>> | :END:
>> |
>> | first contact: $0
>> `----
>
> Thats what I thought, that a single :ADDRESS: property is not very
> usefull or practical. 

You loose meta information and semantic description.

With my method you can generate sparse trees with people living in a
certain street, town or such things.

> So there is not something like a nested property,
> each piece of information needs its own property. 

I do think so. But I am new to Org-mode and might still miss certain
details.

> I think your list is pretty complete and usable. 

Thanks.

>> My current tags for contacts are defined in the header of my
>> contacts.org:
>>
>> ,----[ first line of my contacts.org ]
>> | #+TAGS: job(j) friends(f) health(e) hotels(o) restaurants_bars(r) \
>> |         sport(s) students_TU(t) relatives(r) company(c)
>> `----
>
> [how do you produce this nice insertions in your email?]

As an Emacs user, you might not be delighted with my answer: I am
using mutt[3] as MUA[4]. There I can choose my editor freely. For
this purpose I am using vim 7.1. In vim I can use «boxes»[5]:

,----[ a line from my .vimrc ]
| map ;1 <ESC>:'<,'>!boxes -d boxquote
`----

But I also used to use Emacs for mail composing years ago and I do
recall a similar method there.

> Thanks for your help

You're welcome!

  3. http://www.mutt.org/
  4. http://en.wikipedia.org/wiki/Mail_user_agent
  5. http://boxes.thomasjensen.com/
  6. As I recognize here, the vim referencing mechanism seem to be
     confused by the $1 and $2 from above and started with [3]. Cute.
-- 
Karl Voit




reply via email to

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