Registry / logging / log4rs

log4rs

JSON →
library1.4.0rscratesunverified

A highly configurable multi-output logging implementation for the `log` facade, supporting file, console, and syslog appenders.

# Cargo.toml [dependencies] log4rs = "1.4.0"
INSTALL
IMPORT
SIG · LOG4RS
L
log4rs
loggingrustv1.4.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

init_file
use log4rs::init_file;

Initializes logging from a YAML configuration file and logs an info message.

use log4rs::init_file; use log::info; fn main() { init_file("log4rs.yaml", Default::default()).unwrap(); info!("Application started"); }
Debug
Known issues
gotchaRequires the log crate as a dependency for the log macros.
fix
Add `log` to your Cargo.toml dependencies.
affects: *
Upgrade
Version history
1.4.0latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
22 hits · last 30 days
node
20
OpenAI (training)
1
Resources
log4rs — cargo add log4rs · libregistry