Closed EthanYidong closed 2 years ago
Yeah, that definitely doesn't sound right. Is there a way to specify that a dependency is only for the binaries maybe?
Is dev-dependencies
not it?
Also, perhaps take a look at argh, which is a lot like structopt, but leaner & lighter in dependencies.
Is
dev-dependencies
not it?
Apparently not.
If I'm not mistaken, dependencies only used in binaries are mime_guess
, stderrlog
, exitfailure
and structopt
.
You can use workspaces and cleanup the repo. keep project in this repo split code binaries and lib in two crates something like:
in root Cargo.toml you just put [workspace] members = ["libwl-clipboard", "wl-clipboard-tools"]
then in the subdirs you add the "real" cargo.toml and its dependencies.
libwl-clipboard # publish as new crate wl-clipboard-tools # publish as second crate (the binaries)
mark the old crate as deprecated.
Closed by #19.
Using this crate as a library requires pulling and building
structopt
which is unnecessary and introduces 100+ extra dependencies. Creating a workspace and a separate crate for the binaries would solve this.