Gcalcli

Since Goobook is giving me access to my address book from the command line, the calendar is was the next step.

The requirement is more like being able to add appointments on the fly via command-line than to edit all the details. That way I could just putt in reminders and appointments and make sure I don’t forget about them.

Using the Web-Interface or other GUI base APIs if of course also a possibility, but to be honest: it’s more like suffering compared to just running one command and it’s done.

That said gcalcli (Google Calendar Command Line Interface) is surprisingly simple to install and simple use. If it’s not already in your repository, just download and install it.

Configure access to your Google Calendar via

~/.gcalclirc

or any other file you might solemnly choose for holding your credentials.

Just put in your data and save the file:

[gcalcli]
user: yourusername
pw: yourpassword

Then you can already start using tool and query your calendar.

Just to get a quick overview about the next five day:

$ gcalcli agenda
Thu May 10  12:00pm  Kaffe med E.
    7:30pm  Konsert

Fri May 11   12:00am  Nytt B.
   12:00am  Fødselsdagen til N.A.

I’m not going into too many details here on how to display. For me it’s more important on setting up new appointments.

$ gcalcli quick
$ gcacli quick '5pm 10/31 Trick or Treat'

If gcalcli doesn’t understand your time specification, it will still create an entry in you calendar, but starting at the moment you ran the command, lasting one hour and with all the event information as description in it.

Creating some alias for this makes it even use-able. Typing the whole command just takes too long.

alias gc='gcalcli agenda'
alias gcw='gcalcli calw 1'

It currently doesn’t seem to support deleting entries or to modify them. Yes, that’s a bit of a downside, but a step forward into the right direction.