File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -258,6 +258,10 @@ enum BuildSubcommand {
258258 #[ structopt( name = "CRATE_VERSION" ) ]
259259 crate_version : Option < String > ,
260260
261+ /// Url for registry different from cratesio
262+ #[ structopt( name = "CRATE_REGISTRY" ) ]
263+ crate_registry : Option < String > ,
264+
261265 /// Build a crate at a specific path
262266 #[ structopt(
263267 short = "l" ,
@@ -304,6 +308,7 @@ impl BuildSubcommand {
304308 Self :: Crate {
305309 crate_name,
306310 crate_version,
311+ crate_registry,
307312 local,
308313 } => {
309314 let mut builder = rustwide_builder ( ) ?;
@@ -313,13 +318,12 @@ impl BuildSubcommand {
313318 . build_local_package ( & path)
314319 . context ( "Building documentation failed" ) ?;
315320 } else {
316- let registry_url = ctx. config ( ) ?. registry_url . clone ( ) ;
317321 builder
318322 . build_package (
319323 & crate_name. ok_or_else ( || err_msg ( "must specify name if not local" ) ) ?,
320324 & crate_version
321325 . ok_or_else ( || err_msg ( "must specify version if not local" ) ) ?,
322- registry_url
326+ crate_registry
323327 . as_ref ( )
324328 . map ( |s| PackageKind :: Registry ( s. as_str ( ) ) )
325329 . unwrap_or ( PackageKind :: CratesIo ) ,
You can’t perform that action at this time.
0 commit comments