How joshgermon/cubby works
Main Components
a) Core Components:
• Monitor Module (monitor.c/h): Handles device event listening using systemd/udev
• Backup Module (backup.c/h): Manages rsync backup operations
• Notifier Module (notifier.c/h): Handles status notifications
• CLI Interface (cli.c/h): Manages user interactions
• Utils Module (utils.c/h): Contains shared utilities
b) External Dependencies:
• systemd/udev (for device monitoring)
• rsync (for backup operations)
• Linux filesystem (for mounting operations)
• CLI Interface |
• ↓
• Monitor Service |
• ↓
• Backup Service |
• ↓
• Notification Service |
Data Flow Representation
• CLI → Monitor: Configuration and commands
• Monitor → Backup: Device event triggers
• Backup → Notifier: Progress updates
• System Events → Monitor: USB/SD card events
Component Details
Monitor Service:
• Monitor Service |
• SD-Device API |
• Event Listening |
• Device Mounting |
Backup Service:
• Backup Service |
• rsync Interface |
• Path Management |
• Timestamp Dirs |
Implementation Notes
• The event-driven nature of the system
• Clear separation between monitoring and backup operations
• Security boundaries (root permissions)
• File system interaction points
Keep the focus on the core functionality: device monitoring → mounting → backup, while showing the supporting components that make this possible.
Remember to highlight the specific Linux dependencies (systemd, udev) as they are crucial to the system's operation and represent important platform constraints.