From da868bb02cb2a30d46f0ba15664c59f21b15ad58 Mon Sep 17 00:00:00 2001 From: zjp Date: Sat, 23 Nov 2024 10:58:19 +0800 Subject: [PATCH] use prelude from os-checker-plugin --- Cargo.lock | 23 ++++++++++++++++++----- Cargo.toml | 4 +++- src/generate_rustdoc.rs | 7 ++----- src/main.rs | 2 +- 4 files changed, 24 insertions(+), 12 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 8fe59e7..0dc1456 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -433,10 +433,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775" [[package]] -name = "os-checker-plugin-cargo" -version = "0.1.0" +name = "os-checker-plugin" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ff03285485c2fa9dc5583879bc0d5aeb10bd4b231849b39f6aa4dfbb17b3331" +checksum = "4cf3e4a747d1ab4a28fdb25b71a87b78c7a404ba00208f6c5b743805c776ee03" dependencies = [ "camino", "cargo_metadata 0.18.1", @@ -446,13 +446,25 @@ dependencies = [ "eyre", "indexmap", "jiff", - "nextest-metadata", - "os-checker-types", "serde", "serde_json", "tracing", "tracing-error", "tracing-subscriber", +] + +[[package]] +name = "os-checker-plugin-cargo" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1cbb8e6eff2c8ec1b2cd36c27c1c2d0e65fd2b147c355a750d9f35c87c1e1436" +dependencies = [ + "eyre", + "nextest-metadata", + "os-checker-plugin", + "os-checker-types", + "serde", + "tracing", "walkdir", ] @@ -466,6 +478,7 @@ dependencies = [ "duct", "eyre", "indexmap", + "os-checker-plugin", "os-checker-plugin-cargo", "serde", "serde_json", diff --git a/Cargo.toml b/Cargo.toml index 7068171..856a807 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -22,5 +22,7 @@ tracing = "0.1" tracing-subscriber = { version = "0.3", features = ["env-filter"] } tracing-error = "0.2" -plugin_cargo = { version = "0.1.0", package = "os-checker-plugin-cargo" } +plugin = { version = "0.1.2", package = "os-checker-plugin" } +# FIXME: 将 Repo 功能移至 plugin,这样就不需要 plugin_cargo +plugin_cargo = { version = "0.1.1", package = "os-checker-plugin-cargo" } diff --git a/src/generate_rustdoc.rs b/src/generate_rustdoc.rs index 1ea1dff..79930ae 100644 --- a/src/generate_rustdoc.rs +++ b/src/generate_rustdoc.rs @@ -1,11 +1,8 @@ use crate::DEPLOY; use duct::cmd; use indexmap::{indexmap, IndexSet}; -use plugin_cargo::{ - prelude::*, - repo::{local_base_dir, Repo}, - write_json, -}; +use plugin::{prelude::*, write_json}; +use plugin_cargo::repo::{local_base_dir, Repo}; use std::sync::LazyLock; static DOCS_URL: LazyLock = LazyLock::new(|| { diff --git a/src/main.rs b/src/main.rs index 2b94ec1..4f00773 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,4 +1,4 @@ -use plugin_cargo::{logger, prelude::*, repos}; +use plugin::{logger, prelude::*, repos}; #[macro_use] extern crate tracing;