Mailing List Archive

Easiest way to purge all contacts
Greetings all,
A while back many of my contacts started to duplicate. I have finally
gotten around to sorting them out in a single vcard file that has no
duplicates. My question is: short of doing a complete reinstall what is
the easiest way to purge all vcard entries from the database so I can
re-add the cleaned versions?

--
Nikolai Lusan <nikolai@lusan.id.au>
Re: Easiest way to purge all contacts [ In reply to ]
On Tue, 21 Apr 2015 20:09:28 +1000
Nikolai Lusan <nikolai@lusan.id.au> wrote:

> Greetings all,
> A while back many of my contacts started to duplicate. I have finally
> gotten around to sorting them out in a single vcard file that has no
> duplicates. My question is: short of doing a complete reinstall what is
> the easiest way to purge all vcard entries from the database so I can
> re-add the cleaned versions?

Collect all cleaned entries in a multi-VCARD file and use the DAViCal
maintenance menu to upload it, overwriting the current contacts.

If you have curl, the following command may be useful (all on a single
line):

curl -q --silent --basic --request PUT
--header "Content-Type: text/vcard; charset=utf-8"
--user "$user:$password" --data-binary "@$vcf"

where $user = username, $password = password and $vcf is the name of the
VCARD data file.

HTH,
Johan