PSR-20 Clock Generator
Generates standards-compliant PSR-20 Clock implementations and unit tests for robust PHP 8.4 time management.
The PSR-20 Clock Generator is a specialized skill for Claude Code designed to automate the creation of a comprehensive time abstraction layer within PHP applications. By generating PSR-20 compliant interfaces and implementations—including SystemClock, FrozenClock, OffsetClock, and MonotonicClock—this tool helps developers decouple business logic from the system clock. This is essential for building testable, high-quality software where time-sensitive operations like subscription expirations, scheduling, and logging need to be verified with deterministic results. The skill follows modern PHP 8.4 standards, utilizing readonly classes and strict typing for maximum reliability.