Commit dbdda29f authored by Kornel's avatar Kornel

Bump

parent 52cd0569
[package]
name = "cargo-upgrades"
version = "0.9.0"
version = "1.0.0"
authors = ["Kornel <[email protected]>"]
categories = ["development-tools::cargo-plugins"]
repository = "https://gitlab.com/kornelski/cargo-upgrades"
......@@ -15,7 +15,7 @@ readme = "README.md"
cargo_metadata = "0.8.1"
cargo_toml = "0.7.0"
clap = "2.33.0"
crates-index = "0.13.1"
quick-error = "1.2.2"
semver = "0.9.0"
dirs = "2.0.1"
crates-index = { git = "https://github.com/frewsxcv/rust-crates-index" }
......@@ -35,12 +35,8 @@ struct Workspace {
impl UpgradesChecker {
pub fn new(manifest_path: Option<&str>) -> Result<Self, Error> {
let crates = std::thread::spawn(|| {
let cache_dir = dirs::cache_dir();
let cache_dir = cache_dir.as_ref().map(|p| p.as_path())
.unwrap_or_else(|| std::path::Path::new("/tmp"));
let index = crates_index::Index::new(cache_dir.join("cargo-upgrades-index"));
let index = crates_index::Index::new_cargo_default();
index.retrieve_or_update()?;
let mut crates = HashMap::with_capacity(40000);
for c in index.crates() {
crates.insert(c.name().to_string().into_boxed_str(), c);
......@@ -123,3 +119,9 @@ fn beta_vs_stable() {
assert!(beta11 > beta1);
assert!(beta11 > v100);
}
#[test]
fn test_self() {
let u = UpgradesChecker::new(None).unwrap();
assert_eq!(0, u.outdated_dependencies().count());
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment