How davidoliver/live_cue works
Key Components to Include:
Frontend Layer
• Assets directory structure (CSS and JavaScript)
• LiveView components, especially the CueLive and AlbumComponent
Backend Layer
• Phoenix Framework components:
• Endpoint (entry point for web requests)
• Router (request routing)
• LiveView handlers
• Controllers
• Core Application Components:
• Collection Manager (handles music file processing)
• Player Interface (integration with cmus)
• Database Interface
External Services
• cmus (audio player)
• ZeroTier (networking layer)
• Local File System (music collection)
Component Relationships
• Flow from music files through the collection processing pipeline
• Interaction between the Player module and cmus
• ZeroTier's network layer spanning across the entire system
Processing Flows
• Two main data flows:
a. Collection Processing Flow:
Files → Parse Collection → Store Data → LiveView Interface
b. Playback Flow:
User Input → LiveView → Player Module → cmus → Audio Output
Key Technical Details
• WebSocket connection for LiveView
• TCP ports (4369 and 9001)
• Supported file formats (FLAC)
• Database interactions
• ZeroTier network integration
Specific Implementation Notes:
• Collection processing pipeline
• Real-time playback synchronization
• LiveView component hierarchy