{"id":19561829,"url":"https://github.com/valantic/php-cs-fixer-config","last_synced_at":"2025-08-12T17:42:17.858Z","repository":{"id":152919462,"uuid":"626521402","full_name":"valantic/php-cs-fixer-config","owner":"valantic","description":null,"archived":false,"fork":false,"pushed_at":"2025-07-14T12:05:50.000Z","size":48,"stargazers_count":1,"open_issues_count":3,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-12T11:41:44.296Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/valantic.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2023-04-11T16:24:14.000Z","updated_at":"2025-07-10T06:10:41.000Z","dependencies_parsed_at":null,"dependency_job_id":"ef9b70c2-4e91-4aab-8d68-c39cd071355d","html_url":"https://github.com/valantic/php-cs-fixer-config","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/valantic/php-cs-fixer-config","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/valantic%2Fphp-cs-fixer-config","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/valantic%2Fphp-cs-fixer-config/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/valantic%2Fphp-cs-fixer-config/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/valantic%2Fphp-cs-fixer-config/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/valantic","download_url":"https://codeload.github.com/valantic/php-cs-fixer-config/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/valantic%2Fphp-cs-fixer-config/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270108504,"owners_count":24528761,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-12T02:00:09.011Z","response_time":80,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-11T05:12:39.517Z","updated_at":"2025-08-12T17:42:17.842Z","avatar_url":"https://github.com/valantic.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# PHP-CS-Fixer Config for valantic Projects\n\n[![Latest Version on Packagist](https://img.shields.io/packagist/v/valantic/php-cs-fixer-config.svg?style=flat-square)](https://packagist.org/packages/valantic/php-cs-fixer-config)\n[![PHPUnit](https://github.com/valantic/php-cs-fixer-config/actions/workflows/phpunit.yml/badge.svg)](https://github.com/valantic/php-cs-fixer-config/actions/workflows/phpunit.yml)\n[![Rector](https://github.com/valantic/php-cs-fixer-config/actions/workflows/rector.yml/badge.svg)](https://github.com/valantic/php-cs-fixer-config/actions/workflows/rector.yml)\n[![PHP-CS-Fixer](https://github.com/valantic/php-cs-fixer-config/actions/workflows/php-cs-fixer.yml/badge.svg)](https://github.com/valantic/php-cs-fixer-config/actions/workflows/php-cs-fixer.yml)\n[![PHPStan](https://github.com/valantic/php-cs-fixer-config/actions/workflows/phpstan.yml/badge.svg)](https://github.com/valantic/php-cs-fixer-config/actions/workflows/phpstan.yml)\n[![Total Downloads](https://img.shields.io/packagist/dt/valantic/php-cs-fixer-config.svg?style=flat-square)](https://packagist.org/packages/valantic/php-cs-fixer-config)\n\nThis package provides standard PHP-CS-Fixer configurations used in projects built by Valantic.\n\n## Installation\n\n```bash\ncomposer require --dev valantic/php-cs-fixer-config friendsofphp/php-cs-fixer\n```\n\n\u003e **Note:** This package requires PHP 8.1 or higher.\n\n\u003e **Note:** `friendsofphp/php-cs-fixer` is _not_ a dependency as to allow the use of e.g. [the Composer bin plugin](https://github.com/bamarni/composer-bin-plugin).\n\n## Usage\n\nCreate a `.php-cs-fixer.php` or `.php-cs-fixer.dist.php` file in your project root with one of the following configurations:\n\n### Basic Configuration\n\n```php\n\u003c?php\n\nrequire_once __DIR__ . '/vendor/autoload.php';\n\nuse Valantic\\PhpCsFixerConfig\\ConfigFactory;\n\nreturn ConfigFactory::createValanticConfig([\n        // Add your custom rules here\n        'declare_strict_types' =\u003e false,\n    ])\n    -\u003esetFinder(\n        PhpCsFixer\\Finder::create()\n            -\u003ein(__DIR__ . '/src')\n            -\u003ein(__DIR__ . '/tests')\n    )\n    // Enable risky rules (recommended as the ruleset includes risky rules)\n    -\u003esetRiskyAllowed(true)\n    // Enable parallel execution\n    -\u003esetParallelConfig(PhpCsFixer\\Runner\\Parallel\\ParallelConfigFactory::detect())\n;\n```\n\n## Development\n\nThis package provides several Composer scripts to help with development:\n\n```bash\n# Run PHP-CS-Fixer in dry-run mode with diff output\ncomposer cs-check\n\n# Run PHP-CS-Fixer to fix code style issues\ncomposer cs-fix\n\n# Run PHPStan for static analysis\ncomposer phpstan\n\n# Run Rector in dry-run mode\ncomposer rector-dry-run\n\n# Run Rector and apply changes\ncomposer rector\n\n# Run PHPUnit tests\ncomposer test\n\n# Run all checks (cs-check, phpstan, rector-dry-run, test)\ncomposer check\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvalantic%2Fphp-cs-fixer-config","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvalantic%2Fphp-cs-fixer-config","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvalantic%2Fphp-cs-fixer-config/lists"}