A terminal-based log viewer with search, filtering, and streaming capabilities.
- Syntax highlighting - Configurable color patterns
- Search and highlight - Search the entire log file and highlight results
- Filtering - Include/exclude patterns for filtering lines
- Event tracking - Define event patterns and track these
- Stream logs from stdin - Pipe logs directly from any command
- Save streams - Export stdin streams to files
Download a precompiled binary for linux here
or build from source by running the install script:
./install.shNote: installs to /usr/local/bin/.
For this you need the stable version of the rust toolchain, instructions can be found here.
View a log file:
lazylog myapp.logView multiple log files:
lazylog myapp_1.log myapp_2.logStream from stdin:
journalctl -f | lazylogColor highlighting patterns can be configured by creating a config.toml file:
~/.config/lazylog/config.toml
Use a custom config file with the -c option:
lazylog -c /path/to/config.toml myapp.logLoad predefined filters from a separate file with the -f or --filters option:
lazylog --filters /path/to/filters.toml myapp.logHighlights - Highlight specific patterns within lines:
highlights = [
{ pattern = "\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}", regex = true }, # IP addresses
{ pattern = "TODO", regex = false, style = { fg = "lightmagenta" } }, # Custom style
]If no style is specified for highlights, a unique color is auto-assigned.
Events - Color entire lines and track events when patterns match:
events = [
{ name = "Error", pattern = " ERROR ", regex = false, style = { fg = "lightred", bold = true } },
{ name = "Warning", pattern = " WARN", regex = false, style = { fg = "yellow" } },
{ name = "Critical", pattern = " CRITICAL ", critical = true, regex = false, style = { bg = "red" } },
]Supported colors: red, green, yellow, blue, magenta, cyan, white, black, gray, lightred, lightgreen, lightyellow, lightblue, lightmagenta, lightcyan, darkgray
See examples/config.toml for a complete configuration example and examples/filters.toml for a filters file example.
Clone the repository and build with Cargo:
cargo buildRun the application:
cargo run -- path/to/logfile.logRun unit tests:
cargo test -- --skip perfRun performance measurements:
cargo test --release --test perf -- --nocapture --test-threads=1This project is being developed with AI assistance (thanks Claude). I find AI really useful for exploring design decisions, implementing first drafts and doing massive refactoring quicker than I could have ever done it without these addictive bowling bumpers — the vision and iterative refinements remain driven by me for now. If something feels "generated" it probably is...