{"id":15645492,"url":"https://github.com/voku/phpdoctor","last_synced_at":"2025-10-16T05:06:45.873Z","repository":{"id":37765348,"uuid":"291821478","full_name":"voku/PHPDoctor","owner":"voku","description":"🏥 PHPDoctor: Check files, full directories or strings for missing or bad PHPDoc types.","archived":false,"fork":false,"pushed_at":"2025-02-07T05:25:49.000Z","size":78,"stargazers_count":53,"open_issues_count":7,"forks_count":3,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-12T08:24:01.030Z","etag":null,"topics":["hacktoberfest","php","phpdoc","static-analysis","types"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/voku.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":".github/CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","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},"funding":{"github":["voku"],"patreon":"voku","custom":"https://www.paypal.me/moelleken"}},"created_at":"2020-08-31T20:48:38.000Z","updated_at":"2023-11-19T18:32:55.000Z","dependencies_parsed_at":"2023-09-24T10:04:21.386Z","dependency_job_id":"6a8d4cf5-da34-4bd0-839c-12a368894b3c","html_url":"https://github.com/voku/PHPDoctor","commit_stats":{"total_commits":49,"total_committers":8,"mean_commits":6.125,"dds":0.6734693877551021,"last_synced_commit":"be905a789ac8871bf2d9a560e2be21d71be3fa5d"},"previous_names":[],"tags_count":14,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/voku%2FPHPDoctor","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/voku%2FPHPDoctor/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/voku%2FPHPDoctor/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/voku%2FPHPDoctor/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/voku","download_url":"https://codeload.github.com/voku/PHPDoctor/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248860136,"owners_count":21173368,"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","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":["hacktoberfest","php","phpdoc","static-analysis","types"],"created_at":"2024-10-03T12:08:11.933Z","updated_at":"2025-10-16T05:06:40.818Z","avatar_url":"https://github.com/voku.png","language":"PHP","readme":"[![Build Status](https://travis-ci.com/voku/PHPDoctor.svg?branch=master)](https://travis-ci.com/voku/PHPDoctor)\n[![Codacy Badge](https://api.codacy.com/project/badge/Grade/2feaf2a179a24a5fac99cbf67e72df2f)](https://www.codacy.com/manual/voku/PHPDoctor?utm_source=github.com\u0026amp;utm_medium=referral\u0026amp;utm_content=voku/PHPDoctor\u0026amp;utm_campaign=Badge_Grade)\n[![Latest Stable Version](https://poser.pugx.org/voku/PHPDoctor/v/stable)](https://packagist.org/packages/voku/PHPDoctor) \n[![License](https://poser.pugx.org/voku/PHPDoctor/license)](https://packagist.org/packages/voku/PHPDoctor)\n[![Donate to this project using Paypal](https://img.shields.io/badge/paypal-donate-yellow.svg)](https://www.paypal.me/moelleken)\n[![Donate to this project using Patreon](https://img.shields.io/badge/patreon-donate-yellow.svg)](https://www.patreon.com/voku)\n\n# 🏥 ***PHPDoc***tor\n\nCheck PHP files or directories for missing types.\n\nIf you already use [PHPStan](https://phpstan.org/r/db8ec6af-8815-444e-b533-2717ccb643c6) for your type checks but sometimes someone \nin the team still commit non typed code, then PHPDoctor is for you.\n\n### Install via \"phar\" (**recommended**)\n\nhttps://github.com/voku/PHPDoctor/releases\n\n### Install via \"composer require\"\n\n```shell\ncomposer require-dev voku/phpdoctor\n```\n\n### Quick Start\n\n```\nUsage:\n  analyse [options] [--] \u003cpath...\u003e\n\nArguments:\n  path                                                                                   The path to analyse\n\nOptions:\n      --autoload-file[=AUTOLOAD-FILE]                                                    The path to your autoloader. [default: \"\"]\n      --access[=ACCESS]                                                                  Check for \"public|protected|private\" methods. [default: \"public|protected|private\"]\n      --skip-ambiguous-types-as-error[=SKIP-AMBIGUOUS-TYPES-AS-ERROR]                    Skip check for ambiguous types. (false or true) [default: \"false\"]\n      --skip-deprecated-functions[=SKIP-DEPRECATED-FUNCTIONS]                            Skip check for deprecated functions / methods. (false or true) [default: \"false\"]\n      --skip-functions-with-leading-underscore[=SKIP-FUNCTIONS-WITH-LEADING-UNDERSCORE]  Skip check for functions / methods with leading underscore. (false or true) [default: \"false\"]\n      --skip-parse-errors[=SKIP-PARSE-ERRORS]                                            Skip parse errors in the output. (false or true) [default: \"true\"]\n      --path-exclude-regex[=PATH-EXCLUDE-REGEX]                                          Skip some paths via regex e.g. \"#/vendor/|/other/.*/path/#i\" [default: \"#/vendor/|/tests/#i\"]\n```\n\n### Demo\n\nParse a string:\n```php\n$code = '\n\u003c?php declare(strict_types = 1);   \n     \nclass HelloWorld\n{\n    /**\n     * @param mixed $date\n     */ \n    public function sayHello($date): void\n    {\n        echo \\'Hello, \\' . $date-\u003eformat(\\'j. n. Y\\');\n    }\n}';\n\n$phpdocErrors = PhpCodeChecker::checkFromString($code);\n\n// [8]: missing parameter type for HelloWorld-\u003esayHello() | parameter:date']\n```\n\n### Ignore errors\n\nYou can use ```\u003cphpdoctor-ignore-this-line/\u003e``` in @param or @return phpdocs to ignore the errors directly in your code.\n\n```php\n/**\n * @param mixed $lall \u003cp\u003ethis is mixed but it is ok, because ...\u003c/p\u003e \u003cphpdoctor-ignore-this-line/\u003e\n *\n * @return array \u003cphpdoctor-ignore-this-line/\u003e\n */\nfunction foo_ignore($lall) {\n    return $lall;\n}\n```\n\n### Building the PHAR file\n\nPrepare: https://github.com/phar-io/phive\n\n```bash\nphive install humbug/box\nphp tools/box compile --debug\n```\n\n### Support\n\nFor support and donations please visit [Github](https://github.com/voku/simple_html_dom/) | [Issues](https://github.com/voku/simple_html_dom/issues) | [PayPal](https://paypal.me/moelleken) | [Patreon](https://www.patreon.com/voku).\n\nFor status updates and release announcements please visit [Releases](https://github.com/voku/simple_html_dom/releases) | [Twitter](https://twitter.com/suckup_de) | [Patreon](https://www.patreon.com/voku/posts).\n\nFor professional support please contact [me](https://about.me/voku).\n\n### Thanks\n\n- Thanks to [GitHub](https://github.com) (Microsoft) for hosting the code and a good infrastructure including Issues-Managment, etc.\n- Thanks to [IntelliJ](https://www.jetbrains.com) as they make the best IDEs for PHP and they gave me an open source license for PhpStorm!\n- Thanks to [Travis CI](https://travis-ci.com/) for being the most awesome, easiest continous integration tool out there!\n- Thanks to [StyleCI](https://styleci.io/) for the simple but powerfull code style check.\n- Thanks to [PHPStan](https://github.com/phpstan/phpstan) \u0026\u0026 [Psalm](https://github.com/vimeo/psalm) for really great Static analysis tools and for discover bugs in the code!\n","funding_links":["https://github.com/sponsors/voku","https://patreon.com/voku","https://www.paypal.me/moelleken","https://www.patreon.com/voku","https://paypal.me/moelleken","https://www.patreon.com/voku/posts"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvoku%2Fphpdoctor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvoku%2Fphpdoctor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvoku%2Fphpdoctor/lists"}