1
1
mirror of https://github.com/casey/just.git synced 2024-09-11 05:55:31 +03:00

Remove logging (#2305)

This commit is contained in:
Casey Rodarmor 2024-08-07 14:53:28 -07:00 committed by GitHub
parent f9c2479af8
commit 0b669a2fc8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 1 additions and 47 deletions

31
Cargo.lock generated
View File

@ -423,29 +423,6 @@ version = "1.13.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0"
[[package]]
name = "env_filter"
version = "0.1.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4f2c92ceda6ceec50f43169f9ee8424fe2db276791afde7b2cd8bc084cb376ab"
dependencies = [
"log",
"regex",
]
[[package]]
name = "env_logger"
version = "0.11.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e13fa619b91fb2381732789fc5de83b45675e882f66623b7d8cb4f643017018d"
dependencies = [
"anstream",
"anstyle",
"env_filter",
"humantime",
"log",
]
[[package]]
name = "errno"
version = "0.3.9"
@ -545,12 +522,6 @@ dependencies = [
"windows-sys 0.52.0",
]
[[package]]
name = "humantime"
version = "2.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4"
[[package]]
name = "iana-time-zone"
version = "0.1.60"
@ -611,12 +582,10 @@ dependencies = [
"dirs",
"dotenvy",
"edit-distance",
"env_logger",
"executable-path",
"heck 0.5.0",
"lexiclean",
"libc",
"log",
"num_cpus",
"once_cell",
"percent-encoding",

View File

@ -30,11 +30,9 @@ derivative = "2.0.0"
dirs = "5.0.1"
dotenvy = "0.15"
edit-distance = "2.0.0"
env_logger = "0.11.0"
heck = "0.5.0"
lexiclean = "0.0.1"
libc = "0.2.0"
log = "0.4.4"
num_cpus = "1.15.0"
once_cell = "1.19.0"
percent-encoding = "2.3.1"

View File

@ -750,10 +750,7 @@ impl Config {
}
pub(crate) fn run(self, loader: &Loader) -> RunResult {
if let Err(error) = InterruptHandler::install(self.verbosity) {
warn!("Failed to set CTRL-C handler: {error}");
}
InterruptHandler::install(self.verbosity).ok();
self.subcommand.execute(&self, loader)
}
}

View File

@ -38,7 +38,6 @@ pub(crate) use {
edit_distance::edit_distance,
lexiclean::Lexiclean,
libc::EXIT_FAILURE,
log::{info, warn},
once_cell::sync::Lazy,
regex::Regex,
serde::{

View File

@ -6,17 +6,8 @@ pub fn run(args: impl Iterator<Item = impl Into<OsString> + Clone>) -> Result<()
#[cfg(windows)]
ansi_term::enable_ansi_support().ok();
env_logger::Builder::from_env(
env_logger::Env::new()
.filter("JUST_LOG")
.write_style("JUST_LOG_STYLE"),
)
.try_init()
.ok();
let app = Config::app();
info!("Parsing command line arguments…");
let matches = app.try_get_matches_from(args).map_err(|err| {
err.print().ok();
err.exit_code()