Skip to content

Commit f7d78b8

Browse files
committed
Update top-crates to Cargo 0.82
1 parent d063578 commit f7d78b8

File tree

3 files changed

+30
-40
lines changed

3 files changed

+30
-40
lines changed

top-crates/Cargo.lock

Lines changed: 24 additions & 37 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

top-crates/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ license = "MIT OR Apache-2.0"
99
repository = "https://github.com/rust-lang/rust-playground"
1010

1111
[dependencies]
12-
cargo = "0.81.0"
12+
cargo = "0.82.0"
1313
itertools = "0.13.0"
1414
reqwest = { version = "0.12.0", features = ["blocking"] }
1515
semver = { version = "1.0.11", features = ["serde"] }

top-crates/src/lib.rs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ use cargo::{
1010
},
1111
sources::{
1212
source::{QueryKind, Source, SourceMap},
13-
RegistrySource,
13+
RegistrySource, SourceConfigMap,
1414
},
1515
util::{cache_lock::CacheLockMode, interning::InternedString, VersionExt},
1616
GlobalContext,
@@ -245,8 +245,11 @@ fn make_global_state<'cfg>(
245245
let target_info = TargetInfo::new(config, &[compile_kind], &rustc, compile_kind)
246246
.expect("Unable to create a TargetInfo");
247247

248+
let source_config = SourceConfigMap::empty(config).expect("Unable to create a SourceConfigMap");
249+
248250
// Registry of known packages.
249-
let mut registry = PackageRegistry::new(config).expect("Unable to create package registry");
251+
let mut registry = PackageRegistry::new_with_source_config(config, source_config)
252+
.expect("Unable to create package registry");
250253
registry.lock_patches();
251254

252255
// Source for obtaining packages from the crates.io registry.

0 commit comments

Comments
 (0)