Basic Regex Queries
A plain query will match the content of a file.
This will match the term
client in any of the files in the index. This applies to queries that contain whitespace:
will match any file that contains the exact string
apache license. Non-exact, or fuzzy, matching is on the roadmap. These plain queries are also known as
bloop can also match code symbols. These include identifiers like class, function and variable names:
A regex query returns files whose content matches a regex. Regex queries are enclosed by
bloop supports all UTF-8 expressions supported by Rust's regex crate.
bloop let's you narrow down search results with a set of search filters. These are
lang:. For example, the query:
will match the term
ErrorKind in any file in the
aho-corasick repo. Filters can be combined to construct highly-specific search queries:
repo:BurntSushi/aho-corasick path:src/error ErrorKind lang:Rust
will only match the term
ErrorKind in Rust files in the
aho-corasick repo whose paths contain the pattern
src/error. Note that the ordering of these filters is not important. These two queries are equivalent:
repo:BurntSushi/aho-corasick path:src/error ErrorKind path:src/error ErrorKind repo:BurntSushi/aho-corasick
bloop queries can also match against repo names or file paths.
will return all repos whose name contains the term
rus (e.g. Rust), and
will return all files that contain the pattern
lint-docs in their path.
Any query term can be a regex:
will return files in any
BurntSushi repo which match the regex
How does bloop know what to return when
content: queries are combined? Query terms have an order of precedence:
A search will return the type associated with the highest precedence term in the query. For example:
will match file paths within the specific repo, whereas:
will match file content because the
ErrorKind term takes precedence.
Previous: Getting StartedNext: Code Studio