How telichkin/hurry works
Project Type Analysis
This is a command-line utility tool written in Python that serves as a command shortcut manager/executor. The architecture should focus on the command processing pipeline and configuration management.
Main Components
A. Core Components:
• Command Parser
• Template Engine
• Command Executor
• Configuration Manager
B. External Interfaces:
• File System Interface (for hurry.json)
• Shell Interface (for command execution)
[User Input] → [Command Parser] → [Template Engine] → [Command Executor] → [Shell Output]
• ↑ ↑
• [Configuration Manager] ← [hurry.json]
Component Details
A. Command Parser:
• Input validation
• Command matching
• Argument extraction
• Template pattern recognition
B. Template Engine:
• Template variable extraction (<template> syntax)
• Variable replacement
• Quote handling logic
C. Configuration Manager:
• JSON file reading
• Command mapping storage
• Shortcut resolution
D. Command Executor:
• Shell command preparation
• Recursive hurry command handling
• Command execution pipeline