- If you pass it no arguments, you'll be prompted to choose a search engine and then give search terms, e.g.
jeff$ ./search
[1] amazondotcom Amazon.com
[2] answers Answers.com
[3] creativecommons Creative Commons
[4] eBay eBay
[5] google Google
[6] yahoo Yahoo
Please choose an engine > 6
Input search terms> asdf
Using Yahoo with url 'http://search.yahoo.co...'
Then you'll do a search for http://search.yahoo.com/search?ei=UTF-8&p=asdf%0A.
-
If you give one argument it is a regular expression describing the search engine, e.g.
jeff$ ./search yahoo
Input search terms> asdf
Using Yahoo with url 'http://search.yahoo.co...'
-
If you give more than one argument, the first is treated like a regular expression for the search engine and rest are search terms, e.g.
jeff$ ~/Sites/code/search yahoo asdf
Using Yahoo with url 'http://search.yahoo.co...'