Vcard2person and person2vcard scripts

I archive my contacts in vcard format, but really wanna use the the Haiku person format for contacts, too.

So I threw together a couple scripts for converting in-between them. Kinda hackish, but maybe it’ll be useful for someone else too, jaja.

1 Like

There was already a converter available here: http://www.goodeveca.net/beos/

1 Like

Heck, looks like a fork of that would’ve been a better use of time.

It doesn’t seem to support photos or multi versions yet, but shouldn’t be hard to add.

Cool that was also on my list :relieved:
Does it keep the original vcard data as content of the person file?
I’d really love to stay true to the BeOS spirit here, with the information as file mantra, like the RFC mail message was stored as mail file content, too, for example

In Haiku the file contents is normally used for the jpeg picture of the contact.

I see… strictly speaking I’d rather store this as an attribute, e.g. Base64 encoded, as it doesn’t hold all information about the file, just like an attachment in a mail message.

I see this has already been pondered, but not finished, there was a Google code-in project on GUI matters, and vcard vs. custom attributes was discussed.

I think with an independent vCard translator, this could be solved elegantly, as the core functionality of converting between vCard and a stanard e.g. BContact format could be separated from Tracker and the People application.

Trac issue is https://dev.haiku-os.org/ticket/9374
(focus was on UI but has the best info collected)

As for saving the vcard to a person file, that’s a good idea. So I just pushed a commit to do that.

‘-A’ option saves the vcard to the ‘META:vcard’ attr, and e’-a’ writes the vcard to the person file (so you can’t use a photo with it).

1 Like

Just gave it the first star :smirk:
But now we have a very recent and complete vcard converter which is bash only, and a BeOS app that is outdated :relieved:
Ideal combination imo would be a current and complete C++ Haiku translator that provides a standard model like BContact (also mentioned in the Trac ticket referenced before) that is used by the people app… and/or possibly the previously elsewhere discussed index server that transparently converts or extracts this information in the background… Oh my I digress :relieved:

Why would you base64? Attributes can be binary data, not just strings. Don’t make things more complex than needed :slight_smile:

Haha you’re right, I’m traumatized by working with REST APIs all the time😅