Crabfull is a powerful desktop application built with Rust, using the eframe and egui libraries, for real-time log file viewing. It continuously streams and displays the contents of a log file (log.txt) in a scrollable, code-friendly UI with advanced search capabilities.
- Live Log Streaming: Automatically updates the UI as new lines are appended to
log.txt - Modern GUI: Built with
eguifor a clean, responsive interface - Threaded File Watching: Uses a background thread to monitor the log file for changes
- Real-time Search:
- Instant text search with match highlighting
- Regular expression support with easy toggle
- Smart partial-text highlighting (only matched portions are highlighted)
- Red dot indicators for lines containing matches
- Match counter showing total matches found
- Search Navigation:
- Quick navigation between matches with ⬆⬇ buttons
- Auto-scroll to matches when navigating
- Maintains search state while scrolling
- Line Navigation:
- Jump to specific line number with Enter key support
- Quick jump buttons for ±100, ±1K, ±10K lines
- One-click bottom jump with auto-scroll disable
- Smooth mouse wheel scrolling
- Auto-scroll to latest content (can be toggled)
- Efficient Memory Usage:
- Circular buffer for memory-efficient log viewing
- Windowed line display for handling large files
- Smart partial file loading
- Optimized search highlighting
- Clean Interface:
- Monospace formatting for better readability
- Clear line numbers with separator
- Responsive layout adapting to window size
- Consistent spacing and alignment
- File Reading:
- Pause/Resume log file reading
- Visual pause state indicator
- Background file monitoring
- Display:
- Line numbers display with separator
- Match indicators
- Status information display
- Monospace formatting for better readability
-
Build and Run
# Run with default options (log.txt file and 1M line buffer) cargo run --release # Run with custom log file cargo run --release -- mylog.log # Run with custom buffer size (500K lines) cargo run --release -- --buffer-size 500000 mylog.log # Display help cargo run --release -- --help
-
Log File
- By default, the application reads from
log.txtin the current directory - You can specify a different log file as a command line argument
- If the specified log file does not exist, it will be created automatically
- Any new lines appended to the log file will appear in the viewer in near real-time
- By default, the application reads from
-
Command Line Options
Usage: crabfull [OPTIONS] [LOG_FILE] Arguments: [LOG_FILE] Path to the log file to monitor [default: log.txt] Options: -b, --buffer-size <SIZE> Number of lines to keep in memory [default: 1000000] -h, --help Print help -V, --version Print version -
Basic Controls
- Use the search box to find text in logs
- Toggle "Regex" for pattern matching
- Navigate between matches with ⬆⬇ buttons
- Use jump controls to move through the log file
- Enter a line number to jump to specific location
- Click "Pause Reading" to temporarily stop updating
-
Customizing
- To view a different log file, modify the
log_pathvariable insrc/main.rs
- To view a different log file, modify the
- eframe - egui framework
- egui - Immediate mode GUI
- notify - File system notifications
- regex - Regular expression support
src/main.rs— Main application logic and UIlog.txt— The log file being monitoredCargo.toml— Project manifest and dependencies
MIT or Apache-2.0 (see Rust licensing)
Made with Rust and egui for fast, native log monitoring