It\'s relatively easy to parse the output of the AJAX API using a scripting language:
#!/usr/bin/env python
import urllib
import json
base = \'http://ajax.goog
Untested approach as I don't have access to a unix box currently ...
Assuming "test" is the query string, you could use a simple wget on the following url http://www.google.co.in/#hl=en&source=hp&biw=1280&bih=705&q=test&btnI=Google+Search&aq=f&aqi=g10&aql=&oq=test&fp=3cc29334ffc8c2c
This would leverage Google's "I'm feeling lucky" functionality and wget the first url for you. You may be able to clean up the above url a bit too.