Advertisement

  • AMAZING GOOGLE SEARCHES

    The Code Search interface is similar to the standard Google search page. However, the first thing anyone would notice is the set of syntax instructions and examples given right under the search function.

    1. regexp—a regular expression is meant to search for a pattern of words rather than a set of
    keywords. For example, “hello,\world”. When this is used, the search engine opens up the result page that displays code corresponding to that requirement.
    2. Exact string—to search for an exact string, enclose the search
    string within double quotes. For example, “hello world”
    3. file:regexp—this searches only in files or directories matching
    the regular expression.
    4. package:regexp—this searches for packages containing the spec-
    ified expression. This presents a list of archives in the ZIP or TAR
    formats, for example.
    5. lang:regexp—this crawls through the repositories for code writ-
    ten in the specified language. For example, you could use the
    search string “lang:c++ hello world”.
    6. license:regexp—this searches for code available under a particu-
    lar license. To cite an example, the search string “license:bsd
    hello world” gets you all code licensed under the BSD license,
    containing the words “hello” and/or “world”.

0 comments:

Leave a Reply

first look

Photos