env_logger

Environment-variable-configured logging backend for Rust's log crate

Library
Cargo
v0.11.11
1,064 stars
MIT OR Apache-2.0

Repository Health

Pre-computed score based on development activity, maintenance, community, maturity, and trend momentum. How we score it →
85 /100 Excellent
Development Activity 92
Maintenance 84
Community 76
Maturity 60
Momentum 28

Technical Analysis

AI-assessed by reading the actual repository — architecture, code quality, innovation, and documentation. How we score it →
76 /100 Good
Architecture 78
Code Quality 80
Innovation 62
Learning Curve 85

env_logger is the de-facto default backend for Rust’s log facade, letting you control log levels and per-module filtering entirely through the RUST_LOG environment variable rather than code changes or config files. It writes human-readable, optionally colored output to stderr (or stdout) and supports fine-grained filters like RUST_LOG=my_crate=debug,other_crate=warn.

The project is a Cargo workspace that also publishes env_filter as a separate crate — the underlying filter-parsing engine env_logger builds on — so other logging backends can reuse the same RUST_LOG-style filter syntax without depending on env_logger’s full formatting/writer stack.

What You Get

  • A ready-to-use log::Log implementation activated with a single env_logger::init() call
  • RUST_LOG-style filter syntax supporting per-module and per-level granularity (e.g. my_crate=debug,hyper=warn)
  • Configurable output target (stderr/stdout), timestamp formats, and color support via a Builder API
  • A separate env_filter crate exposing just the filter-string parsing logic for reuse by other logging backends
  • Custom formatter support for fully overriding how each log record is rendered

Common Use Cases

  • Adding basic, zero-config logging output to a CLI tool or service with a single env_logger::init() call
  • Selectively enabling debug-level logs for one dependency while keeping others at warn/error during troubleshooting
  • Building a custom logging backend that wants to reuse env_logger’s RUST_LOG filter parser (env_filter) without its formatter/writer
  • Testing binaries where log verbosity needs to be toggled per test run via environment variables rather than recompiling

Under The Hood

Architecture - the repo is a Cargo workspace with the top-level env_logger package as the umbrella crate (src/lib.rs, src/logger.rs, plus src/fmt for output formatting and src/writer for the stderr/stdout output target) and crates/env_filter as a workspace member providing the standalone RUST_LOG filter-parsing engine that env_logger depends on internally, letting other logging backends adopt the same filter syntax independently. Tech Stack - pure Rust, built on the log crate’s facade pattern (implementing its Log trait), with optional humantime/color-output dependencies gated behind Cargo features, and a workspace-wide Clippy lint configuration ([workspace.lints.clippy]) enforcing a large, curated set of lint rules across both crates. Code Quality - the tests/ directory targets specific historical correctness issues (log-in-log.rs, log_tls_dtors.rs, init-twice-retains-filter.rs, regexp_filter.rs), showing regression coverage for real bugs rather than only happy-path tests, and the workspace enforces a strict shared lint policy (unreachable_pub, unsafe_op_in_unsafe_fn, etc.) across all member crates. API Design - the common path is a single env_logger::init() call with zero required configuration, while a Builder escape hatch exposes format, filter, and target customization for more advanced setups — keeping the learning curve close to zero for the default case while still supporting deep customization.

Used by 16 apps in this directory

C++
68%
Apache 2.0

ClickHouse

Analytics · Data Engineering · Databases

50,116

Open-source column-oriented database that delivers real-time analytical queries on petabyte-scale data with millisecond latency.

View details
95
Repo Health
90
Technical
64
Dependency
Built with
C++ 68%
Python 14%
Updated 5 days ago
Go
32%
Apache 2.0

CubeSandbox

AI Agents · Developer Tools · Security

12,728

Instant, concurrent, hardware-isolated MicroVM sandboxes for AI agents — E2B-API compatible, sub-60ms cold starts, and a built-in zero-trust egress proxy, all self-hostable at scale.

View details
82
Repo Health
88
Technical
63
Dependency
Built with
Go 32%
Rust 26%
C 22%
Updated 1 weeks ago
Rust
59%
MIT

Handy

Productivity · Voice AI

32,320

Free, offline, open-source speech-to-text that pastes directly into any app on Windows, macOS, and Linux.

View details
87
Repo Health
78
Technical
72
Dependency
Built with
Rust 59%
TypeScript 30%
Updated 5 days ago
TypeScript
71%
Other

highlight.io

Analytics · Developer Tools · Monitoring

9,378

Open-source full-stack monitoring that unifies session replay, error tracking, logging, and distributed tracing so you can stop context-switching between tools.

View details
67
Repo Health
78
Technical
65
Dependency
Built with
TypeScript 71%
Go 16%
Updated 1 months ago
TypeScript
67%
MIT

Hoppscotch

Developer Tools

80,529

A lightweight, offline-capable API development ecosystem for testing HTTP, GraphQL, WebSocket, MQTT, and SSE endpoints across web, desktop, and CLI.

View details
91
Repo Health
83
Technical
65
Dependency
Built with
TypeScript 67%
Vue 25%
Updated 1 weeks ago
Rust
52%
Other

Jan

AI Assistants

44,680

Run LLMs 100% locally with full privacy, or connect to cloud AI — your machine, your data, your control.

View details
90
Repo Health
81
Technical
65
Dependency
Built with
Rust 52%
TypeScript 44%
Updated 5 days ago
Rust
48%
MIT

Meetily

AI Assistants · Productivity

31,171

Privacy-first AI meeting assistant that transcribes and summarizes your meetings entirely on your local machine — no cloud, no data leakage.

View details
85
Repo Health
72
Technical
67
Dependency
Built with
Rust 48%
TypeScript 29%
Updated 2 weeks ago
C++
66%
Other

Memgraph

AI Development · Databases

4,581

High-performance in-memory graph database for AI context and real-time analytics

View details
90
Repo Health
79
Technical
69
Dependency
Built with
C++ 66%
Python 18%
Updated 6 days ago
Rust
43%
BSD 3

MicroBin

File Storage

4,571

A self-contained, encrypted paste bin and file-sharing app in Rust with animal-name URLs, burn-after-read, and one-command Docker deployment.

View details
56
Repo Health
67
Technical
71
Dependency
Built with
Rust 43%
HTML 28%
JavaScript 20%
Updated 3 weeks ago

Join founders buildingwith open source

Opinionated takes, migration guides, cost-saving tips, and insights from the open source ecosystem.

Subscribe on Substack
Join 750+ subscribers