-
Notifications
You must be signed in to change notification settings - Fork 33
/
help.html
161 lines (134 loc) · 11.9 KB
/
help.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
<div class="intro">
<h1>Welcome to Searchfox</h1>
<p>
Searchfox is a source code indexing tool for Mozilla Firefox. It
indexes C++, Rust, and JavaScript code. This is the help page for Searchfox.
You can contribute to Searchfox! Visit
our <a href="https://github.com/mozsearch/mozsearch">GitHub page</a>.
Please send bug reports to
<a href="https://bugzilla.mozilla.org/enter_bug.cgi?product=Webtools&component=Searchfox">Bugzilla</a>.
<h3>Query Language</h3>
<p>Searchfox supports both text and file path searches.</p>
<p>Queries entered into the search box use exact string matching. No
search operators are supported. Case insensitive matching and
<a href="https://github.com/google/re2/wiki/syntax">regular expression matching</a>
can be requested with the check boxes.</p>
<p>Path filtering uses globbing. A path matches even if only a substring
of the path is matched by the glob. Use the <code>^</code>
and <code>$</code> operators to match the beginning or end of the
path. Here are some examples:</p>
<dl>
<dt><code>test</code></dt>
<dd>Find all paths containing the substring "<code>test</code>".
<dt><code>^js/src</code></dt>
<dd>Find all paths starting with <code>js/src</code>.
<dt><code>*.cpp</code></dt>
<dd>Find all paths containing "<code>.cpp</code>".
<dt><code>*.cpp$</code></dt>
<dd>Find all paths ending with "<code>.cpp</code>".
<dt><code>^js/src/*.cpp$</code></dt>
<dd>Find all C++ files in <code>js/src</code>, but not in
subdirectories (i.e., <code>*</code> does not match <code>/</code>).
<dt><code>^js/src/**.cpp$</code></dt>
<dd>Find all C++ files in <code>js/src</code> or in subdirectories
(i.e., <code>**</code> matches <code>/</code>).
<dt><code>^js/src/**.{cpp,h}$</code></dt>
<dd>Find all C++ source or header files in <code>js/src</code> or in subdirectories.
</dl>
<h3>Repositories indexed</h3>
<table style="width:100%" border="1">
<thead><tr><th rowspan="2">Repository</th>
<th rowspan="2">Text search</th>
<th rowspan="2">Blame</th>
<th colspan="4">Language semantic analysis</th>
</tr><tr>
<th>JS</th>
<th>IDL</th>
<th>C++</th>
<th>Rust</th>
</tr></thead>
<!-- Repository Text search Blame JS IDL C++ Rust -->
<tbody><tr><td><a href="/mozilla-central/source/">mozilla-central</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> </tr>
<tr><td><a href="/mozilla-mobile/source/">mozilla-mobile</a></td> <td yes></td> <td></td> <td yes></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/comm-central/source/">comm-central</a></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/wubkat/source/">wubkat</a> (webkit index)</td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td yes></td> <td></td> </tr>
<tr><td><a href="/mozsearch/source/">mozsearch (searchfox source)</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> </tr>
<tr><td><a href="/mozsearch-tests/source/">mozsearch tests (searchfox tests)</a></td><td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> </tr>
<tr><td><a href="/mozsearch-mozilla/source/">mozsearch-mozilla (searchfox config)</a></td><td yes></td><td yes></td><td yes></td><td yes></td><td yes></td><td yes></td></tr>
<tr><td><a href="/kaios/source/">KaiOS</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> </tr>
<tr><td><a href="/glean/source/">glean</a></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/nss/source/">nss</a></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/whatwg-html/source/">WHATWG HTML spec</a></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/ecma262/source/">TC39 ECMA262 spec</a></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/mozilla-build/source/">mozilla-build</a></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/mozilla-elm/source/">mozilla-elm</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> </tr>
<tr><td><a href="/mozilla-cedar/source/">mozilla-cedar</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> </tr>
<tr><td><a href="/mozilla-cypress/source/">mozilla-cypress</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> </tr>
<tr><td><a href="/mozilla-beta/source/">mozilla-beta</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> </tr>
<tr><td><a href="/mozilla-release/source/">mozilla-release</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> </tr>
<tr><td><a href="/mozilla-esr128/source/">mozilla-esr128</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> </tr>
<tr><td><a href="/comm-esr128/source/">comm-esr128</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> </tr>
<tr><td><a href="/mozilla-esr115/source/">mozilla-esr115</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> </tr>
<tr><td><a href="/comm-esr115/source/">comm-esr115</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> </tr>
<tr><td><a href="/mozilla-esr102/source/">mozilla-esr102</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> </tr>
<tr><td><a href="/comm-esr102/source/">comm-esr102</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> </tr>
<tr><td><a href="/mozilla-esr91/source/">mozilla-esr91</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> </tr>
<tr><td><a href="/comm-esr91/source/">comm-esr91</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> </tr>
<tr><td><a href="/mozilla-esr78/source/">mozilla-esr78</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> </tr>
<tr><td><a href="/comm-esr78/source/">comm-esr78</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> </tr>
<tr><td><a href="/mozilla-esr68/source/">mozilla-esr68</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> </tr>
<tr><td><a href="/comm-esr68/source/">comm-esr68</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> </tr>
<tr><td><a href="/mozilla-esr60/source/">mozilla-esr60</a></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/comm-esr60/source/">comm-esr60</a></td> <td yes></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> </tr>
<tr><td><a href="/mozilla-esr45/source/">mozilla-esr45</a></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/mozilla-esr31/source/">mozilla-esr31</a></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/mozilla-esr17/source/">mozilla-esr17</a></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/version-control-tools/source/">
version-control-tools</a></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/l10n/source/">l10n</a></td> <td yes></td> <td></td> <td yes></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/llvm/source/">LLVM</a></td> <td yes></td> <td yes></td> <td></td> <td></td> <td yes></td> <td></td> </tr>
<tr><td><a href="/graphviz/source/">Graphviz</a></td> <td yes></td> <td yes></td> <td></td> <td></td> <td yes></td> <td></td> </tr>
<tr><td><a href="/rust/source/">Rust</a></td> <td yes></td> <td yes></td> <td></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/mingw/source/">MinGW-w64</a></td> <td yes></td> <td yes></td> <td></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/mingw-moz/source/">
MinGW-w64 @revision used by m-c</a></td> <td yes></td> <td yes></td> <td></td> <td></td> <td></td> <td></td> </tr>
<tr><td><a href="/mozilla-vpn-client/source/">
mozilla-vpn-client</a></td> <td yes></td> <td yes></td> <td yes></td> <td></td> <td></td> <td></td> </tr>
</tbody></table>
<h3>Cross-referencing</h3>
Once you have arrived at a file, you can mouse over identifiers. If
the color of the identifier changes, then clicking on the identifier
will open a context menu for cross-referencing identifiers.
<p>
<div id="file">
You can see an example by mousing
over “<code><span data-id="#reviveCrashedTab" data-i="0">reviveCrashedTab</span></code>” and
clicking. A context menu will open and you can choose to search for all references to the symbol
(definitions, assignments, and uses).
<p>
In JavaScript code, a second option is sometimes offered. Try mousing
over the same identifier in the following:
“<code>SessionStore.<span data-id="#reviveCrashedTab" data-i="1">reviveCrashedTab</span></code>”.
In this case, you're given the opportunity to search for
<code>SessionStore.reviveCrashedTab</code> (and not
<code>SessionStoreInternal.reviveCrashedTab</code>). Also, since there is only one definition of
<code>SessionStore.reviveCrashedTab</code>, you can jump directly to it.
</div>
<p>
In some cases there is ambiguity whether to search for C++ or
JavaScript implementations of an XPCOM method. Searching for the
method from C++ or JavaScript will find the same-language
implementations of that method as well as the IDL
declaration. Visiting the IDL declaration and searching from there
will yield all implementations.
<h3>Syntax Highlighting</h3>
Searchfox uses semantic syntax highlighting. Types are shown in teal
(blue-green). Definitions are shown in bold. Hovering over an
identifier highlights other uses of that identifier.
</div>
<script>
var ANALYSIS_DATA = [
[[], [{sym: "#reviveCrashedTab", pretty: "property reviveCrashedTab"}]],
[[{sym: "SessionStore#reviveCrashedTab", pretty: "property SessionStore.reviveCrashedTab"}], [{sym: "SessionStore#reviveCrashedTab", pretty: "property SessionStore.reviveCrashedTab"}, {sym: "#reviveCrashedTab", pretty: "property reviveCrashedTab"}]],
];
</script>