Tech Stack
DevDaily is built with modern TypeScript and Node.js tooling:Language
TypeScript 5.7 with strict mode enabled
Runtime
Node.js 18+ with ESM (ECMAScript Modules)
CLI Framework
Commander.js 12 for command parsing
Build Tool
tsup for fast bundling
Core Dependencies
Project Structure
The codebase follows a clean separation of concerns:Commands Layer
src/commands/
src/commands/
CLI command handlers that orchestrate business logic. Commands should be thin - they parse arguments, call core modules, and handle output.Files:
standup.ts- Standup generationpr.ts- PR description generationweek.ts- Weekly summarycontext.ts- Context recoveryrecall.ts- Work history searchsnapshot.ts- Manual snapshot captureinit.ts- Setup wizardconfig.ts- Configuration managementdoctor.ts- System diagnosticsconnect.ts- PM tool connectiondash.ts- Interactive dashboard
Core Layer
src/core/
src/core/
Business logic and domain models. This is where the main functionality lives.Key Modules:
git-analyzer.ts- Git operations using simple-gitcopilot.ts- GitHub Copilot CLI integrationstandup-context.ts- Rich context builder for standupscontext-analyzer.ts- Work pattern analysissnapshot-builder.ts- Snapshot creationwork-journal.ts- Persistent local storageauto-snapshot.ts- Side-effect & hook snapshotsnotifications.ts- Slack/Discord webhooksproject-management.ts- Jira/Linear/GitHub Issuespr-template.ts- PR template detectionpr-prompt.ts- Custom prompt file loadergithub.ts- GitHub API helpersgithub-repo.ts- Repo metadata extraction
Configuration Layer
src/config/
src/config/
Configuration loading and validation using Zod schemas.Features:
- Hierarchical config (local overrides global)
- Separate secrets management
- JSON Schema generation for IDE autocomplete
- Type-safe configuration access
UI Layer
src/ui/
src/ui/
Terminal UI components for rich CLI output.Components:
colors.ts- Color scheme and stylingrenderer.ts- Output formattinghelp.ts- Help screensascii.ts- ASCII art and bannersdashboard.ts- Interactive dashboardkeyboard.ts- Keyboard input handling
Utilities Layer
src/utils/
src/utils/
Shared helper functions and utilities.Utilities:
formatter.ts- Text and markdown formattinghelpers.ts- General helper functionscommitlint.ts- Conventional commit parsingui.ts- UI helper functions
Architecture Patterns
Dependency Flow
1
CLI Entry Point
src/index.ts initializes Commander.js and registers all commands2
Command Handlers
Commands in
src/commands/ parse arguments and orchestrate logic3
Core Logic
Business logic in
src/core/ executes the actual work4
UI & Output
Results are formatted and displayed via
src/ui/ componentsDesign Principle: Commands should be thin orchestrators. Keep business logic in the
core/ layer for better testability and reusability.File Organization
Configuration Hierarchy
DevDaily supports multiple configuration layers:Data Flow
Standup Generation Flow
Work Journal System
The journal system provides persistent memory across commands:1
Snapshot Capture
Triggered automatically after commands or manually via
devdaily snapshot2
Local Storage
Snapshots stored in
~/.config/devdaily/journal/ as JSON files3
Indexing
Snapshots indexed by date, project, branch, and tags
4
Retrieval
Searched via
devdaily recall or aggregated for weekly summariesTypeScript Configuration
The project uses strict mode with comprehensive checks:Build Process
Development Build
- Uses
tsxfor fast TypeScript execution - Auto-rebuilds on file changes
- No bundling required
Production Build
- Bundles to single ESM file in
dist/ - Generates type declarations (
.d.ts) - Includes source maps
- Adds shebang for CLI execution
Next Steps
Setup Guide
Set up your development environment
Testing
Learn about the testing approach
Contributing
Submit your first contribution