Add derive feature (#22)

* chore: remove unused PhantomData

* add derive feature
This commit is contained in:
Al Liu 2023-10-06 01:33:12 +08:00 committed by GitHub
parent 1d36a024ef
commit 6e6678b0e4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 1 deletions

View File

@ -18,9 +18,12 @@ exclude = [
]
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[features]
default = ["derive"]
derive = ["dep:overwatch-derive"]
[dependencies]
overwatch-derive = { path = "../overwatch-derive" }
overwatch-derive = { path = "../overwatch-derive", optional = true }
const-str = "0.3"
color-eyre = "0.6"
async-trait = "0.1"
@ -33,3 +36,4 @@ tracing = "0.1"
[dev-dependencies]
tokio = { version = "1.17", features = ["rt-multi-thread", "sync", "time", "io-std", "io-util", "macros"] }
overwatch-derive = { path = "../overwatch-derive" }

View File

@ -29,3 +29,6 @@ pub mod services;
pub mod utils;
pub type DynError = Box<dyn std::error::Error + Send + Sync + 'static>;
#[cfg(feature = "derive")]
pub use overwatch_derive::*;