### Quick Start Example Source: https://github.com/azuyalabs/yasumi/blob/develop/README.md A simple PHP example demonstrating how to create a holiday provider, retrieve all holidays for a year, get a specific holiday, and check if a date is a holiday. ```php getName() . ': ' . $holiday->format('Y-m-d') . PHP_EOL; } // Get a specific holiday $independenceDay = $holidays->getHoliday('independenceDay'); echo $independenceDay->getName() . ' is on ' . $independenceDay->format('F j, Y') . PHP_EOL; // Check if a date is a holiday $newYearsDay = $holidays->getHoliday('newYearsDay'); if ($newYearsDay !== null) { echo 'New Year\'s Day is a holiday!' . PHP_EOL; } ``` -------------------------------- ### Install Yasumi using Composer Source: https://github.com/azuyalabs/yasumi/blob/develop/README.md This command installs the Yasumi library using Composer. ```shell composer require azuyalabs/yasumi ``` -------------------------------- ### Sign Commits Source: https://github.com/azuyalabs/yasumi/blob/develop/CONTRIBUTING.md Example command to sign commits using the Developer Certificate of Origin (DCO). ```shell git commit -s -m "feat: your change" ``` -------------------------------- ### Project Structure Source: https://github.com/azuyalabs/yasumi/blob/develop/AGENTS.md The directory structure of the Yasumi PHP library. ```text src/Yasumi/\ Yasumi.php # Main entry point / factory Holiday.php # Represents a single holiday SubstituteHoliday.php # Substituted holiday ProviderInterface.php # Contract all providers must implement Translations.php # Holiday name translations Provider/ # One file (or directory) per country/region AbstractProvider.php # Base class for all providers CommonHolidays.php # Reusable holiday calculations (New Year's, etc.) ChristianHolidays.php # Easter and related calculations *.php / */ # Country and sub-region providers Filters/ # Holiday type filters (Official, Bank, etc.) data/ # Translation data files tests/ # PHPUnit tests, mirroring src structure examples/ # Usage examples ``` -------------------------------- ### Key Commands Source: https://github.com/azuyalabs/yasumi/blob/develop/AGENTS.md Common commands for managing the Yasumi project, including testing, code standard checks, and static analysis. ```shell composer test # Run the full PHPUnit test suite composer cs # Check coding standard (dry-run) composer cs-fix # Auto-fix coding standard violations (alias: composer format) composer phpstan # Run static analysis (level 8) ``` -------------------------------- ### Run Tests Alternative Source: https://github.com/azuyalabs/yasumi/blob/develop/CONTRIBUTING.md Alternative command to run the full test suite using PHPUnit directly. ```shell vendor/bin/phpunit ``` -------------------------------- ### Run Tests Source: https://github.com/azuyalabs/yasumi/blob/develop/CONTRIBUTING.md Command to run the full test suite. ```shell composer test ``` -------------------------------- ### Pre-submission Checks Source: https://github.com/azuyalabs/yasumi/blob/develop/CONTRIBUTING.md Commands to run all three checks before submitting a pull request: coding standard check, static analysis, and full test suite. ```shell composer cs # Check coding standard composer phpstan # Static analysis (level 8) composer test # Full test suite ``` -------------------------------- ### Run Specific Test Suite Source: https://github.com/azuyalabs/yasumi/blob/develop/CONTRIBUTING.md Command to run a specific test suite by name. ```shell vendor/bin/phpunit --testsuite Netherlands ``` -------------------------------- ### Format Code Source: https://github.com/azuyalabs/yasumi/blob/develop/CONTRIBUTING.md Command to check and correct code for the PSR-12 Coding Standard using php-cs-fixer. ```shell composer format ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.