This document describes the initial project setup and dependency configuration for Ferrite. The project was initialized as a Rust binary application using Cargo, with all required dependencies specified and verified.
Cargo.toml- Project configuration and dependenciessrc/main.rs- Application entry pointCargo.lock- Locked dependency versions (auto-generated)
The project was created using:
cargo init --name sleek-markdown-editor --binThis created:
- Binary application structure (not a library)
- Default
Cargo.tomlwith package metadata - Basic
src/main.rswith "Hello, world!" template - Rust edition set to 2021
All dependencies were added to Cargo.toml according to the PRD specifications:
| Dependency | Version | Purpose |
|---|---|---|
egui |
0.28 | Immediate mode GUI framework |
eframe |
0.28 | egui application framework |
comrak |
0.22 | CommonMark-compliant markdown parser |
syntect |
5.1 | Syntax highlighting for code blocks |
serde |
1.x | Serialization framework (with derive feature) |
serde_json |
1.x | JSON serialization support |
dirs |
5 | Platform-specific directory paths |
open |
5 | Open URLs in default browser |
rfd |
0.14 | Native file dialogs |
log |
0.4 | Logging facade |
env_logger |
0.11 | Environment-based log configuration |
regex |
1.x | Regular expressions for text processing |
The project was verified to build successfully:
- All 516 dependency packages resolved and locked
- Compilation completed without errors
Cargo.lockgenerated with exact dependency versions
- egui 0.28: Immediate mode GUI that provides fast, cross-platform rendering
- eframe 0.28: Application framework that wraps egui with window management
- comrak 0.22: Fast, CommonMark-compliant markdown parser
- syntect 5.1: Syntax highlighting engine (Sublime Text compatible)
- serde 1.x: Rust's standard serialization framework
- serde_json 1.x: JSON format support for serde
- dirs 5: Provides platform-specific config directories
- rfd 0.14: Native file dialogs (Windows, macOS, Linux)
- open 5: Opens URLs/links in default browser
- log 0.4: Rust logging facade
- env_logger 0.11: Environment-based log configuration (use
RUST_LOG=debug) - regex 1.x: Regular expressions for list/checkbox parsing
cargo buildcargo runcargo checkmarkDownNotepad/
├── Cargo.toml # Project configuration
├── Cargo.lock # Locked dependencies (auto-generated)
├── docs/ # Documentation
│ ├── index.md # Documentation index
│ └── technical/ # Technical documentation
└── src/
├── main.rs # Entry point, eframe setup
├── app.rs # Main App struct, UI rendering
├── state.rs # AppState, Tab, UiState
├── error.rs # Error types
├── config/ # Settings and persistence
├── editor/ # Text editor widget with line numbers
├── files/ # File dialogs and operations
├── markdown/ # Parser, WYSIWYG editor, syntax highlighting
└── theme/ # Theme colors and manager
With the project initialized and dependencies configured, the next phase involves:
- Creating the error handling module (
src/error.rs) - Implementing configuration system
- Building the application state management
- PRD - Full project requirements
- Architecture Overview - Project structure