CLI Commands¶
Fast Craftsmanship CLI provides a set of commands designed to help you maintain high-quality code and follow best practices in your development workflow.
Available Commands¶
Verification Commands¶
- verify: Run code quality checks including type checking, linting, testing, and formatting
- Type checking with mypy
- Linting with flake8
- Testing with pytest
- Format checking with black
Architecture Commands¶
- api: Generate and manage API endpoints
- domain: Work with domain models and business logic
- service: Manage service layer components
- repo: Handle data access and repository patterns
Project Commands¶
- project: Initialize and manage project structure
- docs: Generate and maintain documentation
- test: Create and run tests
Command Design Principles¶
All commands in Fast Craftsmanship follow these core principles:
- Functional Programming
- Pure functions with explicit error types
- Railway-oriented programming using Result types
-
Immutable data structures
-
Type Safety
- Static type checking with mypy
- Tagged unions for error handling
-
Generic types for flexible, type-safe operations
-
User Experience
- Clear, consistent error messages
- Rich terminal output
-
Progress indicators for long-running operations
-
Error Handling
- Structured error types
- Graceful error recovery
- Detailed error reporting
Common Features¶
Every command shares these common features:
- Result-based error handling: All operations return
Result[T, Error] - Rich UI: Consistent terminal output using the UI utilities
- Validation: Input validation and error checking
- Documentation: Detailed help and usage information
Usage Examples¶
Running Verifications¶
Working with Projects¶
See Also¶
- UI Utilities: Documentation for the UI components used by commands
- Error Handling: Guide to error handling patterns
- Type System: Information about type safety and validation