A Rust-based AI agent event collector. This document explains the project structure and development workflow.
devlog/
├── rust/
│ ├── devlog-cli/ # CLI entry point (clap)
│ ├── devlog-adapters/ # Agent-specific log parsers
│ ├── devlog-backfill/ # Historical log processing
│ ├── devlog-buffer/ # SQLite offline event buffer
│ ├── devlog-core/ # Shared types and config
│ ├── devlog-hierarchy/ # Workspace/project resolution
│ └── devlog-watcher/ # File system watching with notify
├── cmd/ # Legacy Go CLI (deprecated)
├── internal/ # Legacy Go internal packages (deprecated)
├── configs/ # Default configuration files
├── docs/ # Documentation
└── specs/ # Feature specifications
- Rust 1.75+
- Make
# Clone the repository
git clone https://github.com/codervisor/devlog.git
cd devlog
# Build the binary
make buildmake build # Build for current platform
make clean # Remove build artifacts
make install # Install to /usr/local/binmake run # Build and run
make fmt # Format code
make lint # Run clippymake test # Run all testsTo add support for a new AI coding agent:
- Create a new file in
rust/devlog-adapters/src/(e.g.,myagent.rs) - Implement the
AgentAdaptertrait:
#[async_trait]
pub trait AgentAdapter: Send + Sync {
fn name(&self) -> &str;
fn parse_log_line(&self, line: &str) -> Result<Option<AgentEvent>>;
async fn parse_log_file(&self, file_path: &Path) -> Result<Vec<AgentEvent>>;
fn supports_format(&self, sample: &str) -> bool;
}- Register in
rust/devlog-adapters/src/lib.rsandrust/devlog-cli/src/main.rs - Add tests in
rust/devlog-adapters/src/myagent.rs
- Follow standard Rust conventions
- Use
make fmtbefore committing - Use
make lintto check for issues - Add tests for new functionality
- Memory safety without garbage collection
- Zero-cost abstractions
- Excellent performance for parsing and I/O
- Strong type system with Result/Option
- Single static binary
- Simplicity: Occam's razor - simple solutions over complex ones
- Type safety: Strong typing throughout
- Testability: All components are testable in isolation
- Extensibility: Easy to add new agent adapters
- Fork the repository
- Create a feature branch
- Make your changes with tests
- Run
make testandmake lint - Submit a PR with a clear description
Apache 2.0 - see LICENSE