From ee5a2c4aba6a49028130a69e63c1060fbf7ff71c Mon Sep 17 00:00:00 2001 From: SeanOMik Date: Sun, 19 Jun 2022 15:03:07 -0400 Subject: [PATCH] Add `lib.rs`, remove `derive_builder` from cargo.toml --- Cargo.lock | 75 +++-------------------------------------------------- Cargo.toml | 4 +-- src/lib.rs | 8 ++++++ src/main.rs | 5 +--- 4 files changed, 14 insertions(+), 78 deletions(-) create mode 100644 src/lib.rs diff --git a/Cargo.lock b/Cargo.lock index 7f89bf1..a7bad6c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -99,18 +99,8 @@ version = "0.13.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453c" dependencies = [ - "darling_core 0.13.4", - "darling_macro 0.13.4", -] - -[[package]] -name = "darling" -version = "0.14.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4529658bdda7fd6769b8614be250cdcfc3aeb0ee72fe66f9e41e5e5eb73eac02" -dependencies = [ - "darling_core 0.14.1", - "darling_macro 0.14.1", + "darling_core", + "darling_macro", ] [[package]] @@ -127,73 +117,17 @@ dependencies = [ "syn", ] -[[package]] -name = "darling_core" -version = "0.14.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "649c91bc01e8b1eac09fb91e8dbc7d517684ca6be8ebc75bb9cafc894f9fdb6f" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn", -] - [[package]] name = "darling_macro" version = "0.13.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835" dependencies = [ - "darling_core 0.13.4", + "darling_core", "quote", "syn", ] -[[package]] -name = "darling_macro" -version = "0.14.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ddfc69c5bfcbd2fc09a0f38451d2daf0e372e367986a83906d1b0dbc88134fb5" -dependencies = [ - "darling_core 0.14.1", - "quote", - "syn", -] - -[[package]] -name = "derive_builder" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d07adf7be193b71cc36b193d0f5fe60b918a3a9db4dad0449f57bcfd519704a3" -dependencies = [ - "derive_builder_macro", -] - -[[package]] -name = "derive_builder_core" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f91d4cfa921f1c05904dc3c57b4a32c38aed3340cce209f3a6fd1478babafc4" -dependencies = [ - "darling 0.14.1", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "derive_builder_macro" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f0314b72bed045f3a68671b3c86328386762c93f82d98c65c3cb5e5f573dd68" -dependencies = [ - "derive_builder_core", - "syn", -] - [[package]] name = "encoding_rs" version = "0.8.31" @@ -693,7 +627,6 @@ dependencies = [ name = "qbittorrent" version = "0.1.0" dependencies = [ - "derive_builder", "reqwest", "serde", "serde_json", @@ -885,7 +818,7 @@ version = "1.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e182d6ec6f05393cc0e5ed1bf81ad6db3a8feedf8ee515ecdd369809bcce8082" dependencies = [ - "darling 0.13.4", + "darling", "proc-macro2", "quote", "syn", diff --git a/Cargo.toml b/Cargo.toml index 2b33589..f489332 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -12,6 +12,4 @@ serde_with = "1.14.0" serde_repr = "0.1" reqwest = { version = "0.11.11", features = ["cookies", "multipart"] } -tokio = { version = "1.19.2", features = ["full"] } - -derive_builder = "0.11.2" \ No newline at end of file +tokio = { version = "1.19.2", features = ["full"] } \ No newline at end of file diff --git a/src/lib.rs b/src/lib.rs new file mode 100644 index 0000000..035b2f2 --- /dev/null +++ b/src/lib.rs @@ -0,0 +1,8 @@ +pub mod torrent; +pub use torrent::*; + +pub mod client; +pub use client::*; + +pub mod error; +pub use error::*; \ No newline at end of file diff --git a/src/main.rs b/src/main.rs index 11ef131..f0b664f 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,9 +1,6 @@ -#[macro_use] -extern crate derive_builder; +/// NOTE: USED FOR TESTING pub mod torrent; -use std::path::Path; - pub use torrent::*; pub mod client;