diff --git a/.cargo/config.toml b/.cargo/config.toml new file mode 100644 index 0000000000..f7eac8b044 --- /dev/null +++ b/.cargo/config.toml @@ -0,0 +1,3 @@ +[build] +# Required for tokio-console support +rustflags = ["--cfg", "tokio_unstable"] \ No newline at end of file diff --git a/lychee-bin/Cargo.toml b/lychee-bin/Cargo.toml index 86613f598e..a21c7a4bcf 100644 --- a/lychee-bin/Cargo.toml +++ b/lychee-bin/Cargo.toml @@ -79,9 +79,7 @@ features = ["fmt", "env-filter"] optional = true [features] -# This is currently unstable and requires `RUSTFLAGS="--cfg tokio_unstable"` -# As such, it needs to bexplicitly enabled to avoid breaking the tests with `--all-features`. -#tokio-console = ["dep:console-subscriber", "dep:tracing-subscriber"] +tokio-console = ["dep:console-subscriber", "dep:tracing-subscriber"] # Compile and statically link a copy of OpenSSL. vendored-openssl = ["openssl-sys/vendored"] @@ -112,4 +110,4 @@ required-features = ["check_example_domains"] [package.metadata.binstall] pkg-url = "{ repo }/releases/download/v{ version }/{ name }-v{ version }-{ target }{ archive-suffix }" bin-dir = "{ bin }{ binary-ext }" -pkg-fmt = "tgz" +pkg-fmt = "tgz" \ No newline at end of file diff --git a/lychee-bin/src/main.rs b/lychee-bin/src/main.rs index 41457e45ff..2b78b95104 100644 --- a/lychee-bin/src/main.rs +++ b/lychee-bin/src/main.rs @@ -115,7 +115,7 @@ enum ExitCode { const LYCHEEIGNORE_COMMENT_MARKER: &str = "#"; fn main() -> Result<()> { - #[cfg(all(feature = "tokio-console"))] + #[cfg(feature = "tokio-console")] console_subscriber::init(); // std::process::exit doesn't guarantee that all destructors will be ran,