October 5, 2006 12:01 AM PDT

Google crawls into source code search

Related Stories

Web giants lure developers

September 1, 2006

Google aims for Web developers' hearts and minds

August 26, 2005
Google is taking its search expertise to one of its favorite audiences: software developers.

The company on Thursday launched a Web site, Google Code Search, which the company says will let programmers search billions of lines of code for tips on how to write their own software.

The service, conceived by the Google Labs early technology group, will crawl publicly available code, most of which is made available through open-source projects. The search and indexing covers code on Web pages and code that resides in compressed files, said Tom Stocky, a product manager at Google.

Google expects that the search engine will be used primarily as a learning tool to help students and serious programmers, rather than a way to find and copy another person's code.

"Most of the code is open source so you can reuse it. But I don't think that's the primary use--it's more about how to learn about things and, when you're building open-source packages, to make sure you doing it the right way," Stocky said.

For example, a developer may need to write a function as part of an application and search the Web to see other examples.

Google engineers, many of whom participate in open-source projects, already use these code-searching capabilities internally. Since it is a Google Labs project, the company is not yet seeking to make money through ads linked to searches, Stocky said.

The search engine will let people do both keyword search and "regular expressions," which allow people to search a specified pattern, he said. For example, a person could narrow a search to JavaScript functions, which will help find more examples, Stocky said.

As it does with many of its services, Google will release an application programming interface (API) to create an XML feed based on a specific query.

Although it doesn't sell programming tools, Google has an active developer-outreach program and relies on third-party programmers to enhance its services.

For example, developers have created popular mashup applications that display information from a Web site, such a real-estate listings site, using Google Maps.

"More and more (the developer community) is the way Google products are getting to scale," Stocky said. "We think developers can really improve Google products and use Google technology to improve their own products."

See more CNET content tagged:
Google Inc., open source, programmer, source code, code


Join the conversation!
Add your comment
Google Crawals URL is NOT Working
I tried the URL link given in above topic but that is not working.

Google is the best. I attended a contest conducted by Google, named "WordMaster" and it was the best around the corner.

I am Mitul Bhavsar, a freelancer web designer / website developer. Look at my website: <a class="jive-link-external" href="http://www.designwebgraphic.com" target="_newWindow">http://www.designwebgraphic.com</a>

I am sure Google will control over a web-world soon in the future.
Posted by designwebgraphic (1 comment )
Reply Link Flag
Corrrected link
Posted by sparky_132 (3 comments )
Link Flag
Broken link to Google Code Search
I noticed the link to the Google Code Search in the article is broken. I think I see what's wrong though.

Your link was the following:
<a class="jive-link-external" href="http://dw.cbsi.com/redir?destUrl=Google.com%2Fcodesearch&#38;siteId=3&#38;oId=2100-1024-6122819&#38;ontId=1023&#38;lop=nl.ex" target="_newWindow">http://dw.cbsi.com/redir?destUrl=Google.com%2Fcodesearch&#38;siteId=3&#38;oId=2100-1024-6122819&#38;ontId=1023&#38;lop=nl.ex</a>
However, that redirects to <a class="jive-link-external" href="http://dw.cbsi.comgoogle.com/" target="_newWindow">http://dw.cbsi.comgoogle.com/</a> (a spam site since comgoogle.com is being cybersquatted). The reason is that the "http://" was omitted from redirect link, which apparently breaks Cnet's redirect script.

Adding back the <a class="jive-link-external" href="http://" target="_newWindow">http://</a> and changing Google.com to www.google.com, the correct URL should be:
<a class="jive-link-external" href="http://dw.cbsi.com/redir?destUrl=http%3A%2F%2Fwww.google.com%2Fcodesearch&#38;siteId=3&#38;oId=2100-1024-6122819&#38;ontId=1023&#38;lop=nl.ex" target="_newWindow">http://dw.cbsi.com/redir?destUrl=http%3A%2F%2Fwww.google.com%2Fcodesearch&#38;siteId=3&#38;oId=2100-1024-6122819&#38;ontId=1023&#38;lop=nl.ex</a>

Posted by jje007 (1 comment )
Reply Link Flag
Good catch, looks like CNET's programmers are going to make use of this one real quick ;).

Actually its probably a really easy fix but.. yeah
Posted by 8ball629 (80 comments )
Link Flag
Posted by sparky_132 (3 comments )
Link Flag
URL to Google Code Search is now fixed
thanks for spotting the problem.
Posted by mlamonica (330 comments )
Link Flag
Can it crawl HERE? ...
... and maybe figure out what is going on at that odd military site in China recently discovered using Google Earth?

Articles with pictures:
<a class="jive-link-external" href="http://www.theregister.co.uk/2006/07/19/huangyangtan_mystery/" target="_newWindow">http://www.theregister.co.uk/2006/07/19/huangyangtan_mystery/</a>
<a class="jive-link-external" href="http://www.smh.com.au/news/web/the-riddle-of-chinas-area-51/2006/08/14/1155407679963.html" target="_newWindow">http://www.smh.com.au/news/web/the-riddle-of-chinas-area-51/2006/08/14/1155407679963.html</a>

Google Earth forum post:
<a class="jive-link-external" href="http://bbs.keyhole.com/ubb/showthreaded.php/Cat/0/Number/484568" target="_newWindow">http://bbs.keyhole.com/ubb/showthreaded.php/Cat/0/Number/484568</a>

That's the place in the middle of the desert where the Chinese Army has constructed a scale-model replica of the entire region of Aksai Chin (occupied by China since the 1962 war with India). At 1:500, it's still 700 by 900 meters big ( = several football fields). Next to it is a base with dozens of troop transporters seen coming and going. The duplicate shows everything: rivers, lakes, roads and snow-capped mountains. It's basically a landscape within a landscape.

The problem is that nobody has been able to figure out the function of this thing. The world's biggest miniature golf course, perhaps? China's own Area 51? That's why it's the subject of so much discussion in the blogosphere. The discoverer even had to set up his own blog: foundinchina.blogspot.com

Any ideas?
Posted by tania3000 (18 comments )
Reply Link Flag
Spammer alert
Will you STOP spamming about this military site!
I'm getting sick of seeing it posted in every talkback thread.
Posted by Marcus Westrup (630 comments )
Link Flag
That will be a nice feature for developers!
Posted by rajender.tella (2 comments )
Reply Link Flag
Agreed, it's a fantastic resource. I've already used it a few times to see how people are using some language features...
Posted by martin1212 (156 comments )
Link Flag
its amazing
it was very useful for the software developers
Posted by gvsunil1 (1 comment )
Reply Link Flag

Join the conversation

Add your comment

The posting of advertisements, profanity, or personal attacks is prohibited. Click here to review our Terms of Use.

What's Hot



RSS Feeds

Add headlines from CNET News to your homepage or feedreader.