Can you extract/add contacts in vcard formats?

Can you get/add appointments/tasks/todos in icalendar format?

I discovered some users of vPim using a cmd-line tool (of Evolutions, I
guess) to pull everything out in vCard format, and then use a tool from
vPim to search for email addrs, and convert to either a mutt aliases
file, or to the mutt query format.

It would be easier and faster, I'd think, to do this directly. I'll send
you the scripts so you can see what the formats are, you might find it
interesting to add tools like this.

I'm interested in adding icalendars because I use mutt for email, and I
process incoming calendars (meetings, mostly) with it. I would use
Evolution for a pretty display of that info.

Thanks,
Sam

Wrote Tom Copeland <tom / infoether.com>, on Mon, Mar 21, 2005 at 11:54:54PM +0900:
> I've just released v0.1 of Revolution, a Ruby binding to the excellent
> Evolution personal information management (PIM) application.  
> 
> Here's how you can use it to get to contact/calendar/task information:
> 
> ==============================
> require 'revolution'
> 
> r = Revolution::Revolution.new
> 
> r.get_all_contacts.each {|c|
>         puts "First name: #{c.first_name}"
>         puts "Last name: #{c.last_name}"
>         puts "Work email: #{c.work_email}" if !c.work_email.nil?
> }
> 
> last_week = Time.new.to_i-(7*24*60*60)
> next_week = Time.new.to_i+(7*24*60*60)
> r.get_all_appointments(last_week, next_week).each {|appt|
>         puts "Summary: #{appt.summary}"
>         puts "Location: #{appt.location}"
>         puts "Start time: #{appt.start}"
> }
> 
> r.get_all_tasks.each {|t|
>         puts "Task (#{t.uid})"
>         puts "Summary: #{t.summary}"
>         puts "Description: #{t.description.slice(0,70)}"
>         puts "Start date: #{t.start}"
> }
> ==============================
> 
> You can install the Gem using "gem install --remote revolution", or you
> can download various things here:
> 
> http://rubyforge.org/frs/?group_id=576
> 
> and more documentation is available here:
> 
> http://revolution.rubyforge.org/
> 
> Thanks to InfoEther (http://infoether.com/) for sponsoring development
> of this library!
> 
> Yours,
> 
> Tom
> 
> 
> 

-- 
Sam Roberts <sroberts / certicom.com>