How to Install and Use GoogleCL

Google just launched a new project called GoogleCL, which will let you use some Google services from the command-line and no need to visit their websites.

Up till now, GoogleCL has supported 6 Google services, including Blogger, Picasa Web, YouTube, Gmail Contact, Google Docs and Google Calendar.

Below are the easy steps for you to install and use GoogleCL.

I. How to install GoogleCL

To install GoogleCL, you will need Python, Gdata and GoogleCL, below are the steps for you to download and install these three softwares:

Step 1. To install Python

Go to download the right python client for your computer from the Python download page, and then install the software in your computer.

Step 2. Adding Python to DOS Path

For Windows users, you need to add the Python installation fold path (such as C:\python26) as the Variable Value for the System Variable Path, and you can check out below video for how to do that:

You can neglect the above two steps if you have already installed Python before.

Step 3. To install Gdata

Download the Gdata python client from its Google Code page, extract the file, and then run below commend:

python setup.py install

For example, if the file is extracted to below path:

d:\gdata-2.0.10

You can run the cmd.exe program and enter the comments in below image:

You can also neglect this step if you have already installed Gdata before.

Step 4. To install GoogleCL

The installation of GoogleCL is similar to Gdata, just download the GoogleCL compressed file from its Google Code page, extract the file and then run below commend:

python setup.py install

For example, if the file is extracted to below path:

D:\googlecl-0.9.5

You can run the cmd.exe program and enter the comments in below image:

After the above 4 steps, the installation of GoogleCL will be finished.

II. How to use GoogleCL

As mentioned above, you just need to add some commend lines, so the usage of GoogleCL is easy.

Step 1. To edit the GoogleCL config file

Since you need to log in your Google account and grant access to GoogleCL via your browser, it’s important to automatically launch your browser. To do that, you can find the GoogleCL config file in below directory:

C:\Documents and Settings\Administrator\.googlecl

Open the config file and add below code:

auth_browser = (browser)

For example, if you want to grant access to GoogleCL via Firefox browser, just replace (browser) with the Firfox.exe path, such as below:

auth_browser = C:\Program Files\Mozilla Firefox\firefox.exe

Step 2. To open the google file

You can find the “google” file in the scripts folder of the build directory, such as below:

googlecl-0.9.5\build\scripts-2.6

Open the google file with Python, enter any supported scripts and your Gmail address, then you will see an authorization page like below:

Click on the Grant access button, then you are done, you have to do this once for every google service supported by GoogleCL.

Step 3. To run GoogleCL with scripts

GoogleCL has supported Blogger, Picasa Web, YouTube, Gmail Contact, Google Docs and Google Calendar, so there will be a few different scripts for every google services, and you can find out all the available script samples on its Google Code page.

For example, if you want to update your Blogger with a new post, you can run some scripts like below:


blogger post --tags "GoogleCL" --title "How to Use GoogleCL" "Check out FreeNuts.com for how to use GoogleCL, it is cool."

Then you will see a new post on your Blogger like below:

So, what do you think? Isn’t GoogleCL cool and easy to use?

Bonus

Below are two extra tips for you to use GoogleCL:

1. To create a google.cmd file

Instead to run the google program with Python, you can create a google.cmd file with below codes:

@echo off

SET googlecl_home=D:\googlecl-0.9.5\build\scripts-2.6

python %googlecl_home%\google %*

Remember to replace the scripts folder path with yours, then you can double-click on the google.cmd file and run GoogleCL directly.

2. To use GoogleCL with VPN services

If you are in an area such as China where YouTube, Blogger, Picasa Web and some other Google services are blocked, you can use GoogleCL with these free VPN services.

This entry was posted in Other Free Nuts and tagged , . Bookmark the permalink. Both comments and trackbacks are currently closed.

2 Comments

  1. Posted June 25, 2010 at 12:43 pm | Permalink

    i installed it in debian linux and ubuntu and it works great..

  2. Young
    Posted June 25, 2010 at 12:51 pm | Permalink

    @billy Cheers!