blob: a789ac6c09abbb26a59e3df0fbbcad06ac35e6ad [file] [log] [blame]
Matthew Maurerbd398542019-09-05 16:25:08 -07001'\" t
2.\" Title: cargo-search
3.\" Author: [see the "AUTHOR(S)" section]
4.\" Generator: Asciidoctor 1.5.8
5.\" Date: 2019-01-23
6.\" Manual: \ \&
7.\" Source: \ \&
8.\" Language: English
9.\"
10.TH "CARGO\-SEARCH" "1" "2019-01-23" "\ \&" "\ \&"
11.ie \n(.g .ds Aq \(aq
12.el .ds Aq '
13.ss \n[.ss] 0
14.nh
15.ad l
16.de URL
17\fI\\$2\fP <\\$1>\\$3
18..
19.als MTO URL
20.if \n[.g] \{\
21. mso www.tmac
22. am URL
23. ad l
24. .
25. am MTO
26. ad l
27. .
28. LINKSTYLE blue R < >
29.\}
30.SH "NAME"
31cargo\-search \- Search packages in crates.io
32.SH "SYNOPSIS"
33.sp
34\fBcargo search [\fIOPTIONS\fP] [\fIQUERY\fP...]\fP
35.SH "DESCRIPTION"
36.sp
37This performs a textual search for crates on \c
38.URL "https://crates.io" "" "."
39The matching
40crates will be displayed along with their description in TOML format suitable
41for copying into a \fBCargo.toml\fP manifest.
42.SH "OPTIONS"
43.SS "Search Options"
44.sp
45\fB\-\-limit\fP \fILIMIT\fP
46.RS 4
47Limit the number of results (default: 10, max: 100).
48.RE
49.sp
50\fB\-\-index\fP \fIINDEX\fP
51.RS 4
52The URL of the registry index to use.
53.RE
54.sp
55\fB\-\-registry\fP \fIREGISTRY\fP
56.RS 4
57Name of the registry to use. Registry names are defined in \c
58.URL "https://doc.rust\-lang.org/cargo/reference/config.html" "Cargo config files" "."
59If not specified, the default registry is used, which is defined by the
60\fBregistry.default\fP config key which defaults to \fBcrates\-io\fP.
61.RE
62.SS "Display Options"
63.sp
64\fB\-v\fP, \fB\-\-verbose\fP
65.RS 4
66Use verbose output. May be specified twice for "very verbose" output which
67includes extra output such as dependency warnings and build script output.
68May also be specified with the \fBterm.verbose\fP
69.URL "https://doc.rust\-lang.org/cargo/reference/config.html" "config value" "."
70.RE
71.sp
72\fB\-q\fP, \fB\-\-quiet\fP
73.RS 4
74No output printed to stdout.
75.RE
76.sp
77\fB\-\-color\fP \fIWHEN\fP
78.RS 4
79Control when colored output is used. Valid values:
80.sp
81.RS 4
82.ie n \{\
83\h'-04'\(bu\h'+03'\c
84.\}
85.el \{\
86. sp -1
87. IP \(bu 2.3
88.\}
89\fBauto\fP (default): Automatically detect if color support is available on the
90terminal.
91.RE
92.sp
93.RS 4
94.ie n \{\
95\h'-04'\(bu\h'+03'\c
96.\}
97.el \{\
98. sp -1
99. IP \(bu 2.3
100.\}
101\fBalways\fP: Always display colors.
102.RE
103.sp
104.RS 4
105.ie n \{\
106\h'-04'\(bu\h'+03'\c
107.\}
108.el \{\
109. sp -1
110. IP \(bu 2.3
111.\}
112\fBnever\fP: Never display colors.
113.RE
114.sp
115May also be specified with the \fBterm.color\fP
116.URL "https://doc.rust\-lang.org/cargo/reference/config.html" "config value" "."
117.RE
118.SS "Common Options"
119.sp
120\fB\-h\fP, \fB\-\-help\fP
121.RS 4
122Prints help information.
123.RE
124.sp
125\fB\-Z\fP \fIFLAG\fP...
126.RS 4
127Unstable (nightly\-only) flags to Cargo. Run \fBcargo \-Z help\fP for
128details.
129.RE
130.SH "ENVIRONMENT"
131.sp
132See \c
133.URL "https://doc.rust\-lang.org/cargo/reference/environment\-variables.html" "the reference" " "
134for
135details on environment variables that Cargo reads.
136.SH "EXIT STATUS"
137.sp
1380
139.RS 4
140Cargo succeeded.
141.RE
142.sp
143101
144.RS 4
145Cargo failed to complete.
146.RE
147.SH "EXAMPLES"
148.sp
149.RS 4
150.ie n \{\
151\h'-04' 1.\h'+01'\c
152.\}
153.el \{\
154. sp -1
155. IP " 1." 4.2
156.\}
157Search for a package from crates.io:
158.sp
159.if n .RS 4
160.nf
161cargo search serde
162.fi
163.if n .RE
164.RE
165.SH "SEE ALSO"
166.sp
167\fBcargo\fP(1), \fBcargo\-install\fP(1), \fBcargo\-publish\fP(1)