{"id":13505083,"url":"https://github.com/ovr/phpsa","last_synced_at":"2025-03-29T22:31:26.997Z","repository":{"id":34004933,"uuid":"37760247","full_name":"ovr/phpsa","owner":"ovr","description":"Smart/Static Analyzer(sis) for PHP :bowtie::neckbeard:","archived":true,"fork":false,"pushed_at":"2019-02-27T06:40:47.000Z","size":1773,"stargazers_count":638,"open_issues_count":62,"forks_count":44,"subscribers_count":34,"default_branch":"master","last_synced_at":"2025-03-05T04:19:52.264Z","etag":null,"topics":["analyzer","control-flow","php","php-static-analysis","phpsa"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ovr.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":".github/CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-06-20T06:24:46.000Z","updated_at":"2025-02-16T04:30:50.000Z","dependencies_parsed_at":"2022-07-13T21:35:08.312Z","dependency_job_id":null,"html_url":"https://github.com/ovr/phpsa","commit_stats":null,"previous_names":[],"tags_count":15,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ovr%2Fphpsa","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ovr%2Fphpsa/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ovr%2Fphpsa/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ovr%2Fphpsa/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ovr","download_url":"https://codeload.github.com/ovr/phpsa/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246254077,"owners_count":20747946,"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":["analyzer","control-flow","php","php-static-analysis","phpsa"],"created_at":"2024-08-01T00:00:58.096Z","updated_at":"2025-03-29T22:31:24.466Z","avatar_url":"https://github.com/ovr.png","language":"PHP","funding_links":[],"categories":["Standalone","PHP"],"sub_categories":["Bugs finders"],"readme":"![Logo](http://dmtry.me/img/logos/phpsa.png)\n\nPHPSA - Smart Analyzer for PHP\n===============================\n[![Build Status](https://travis-ci.org/ovr/phpsa.svg?branch=master)](https://travis-ci.org/ovr/phpsa)\n[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/ovr/phpsa/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/ovr/phpsa/?branch=master)\n[![Code Coverage](https://scrutinizer-ci.com/g/ovr/phpsa/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/ovr/phpsa/?branch=master)\n[![Latest Stable Version](https://poser.pugx.org/ovr/phpsa/v/stable.svg)](https://packagist.org/packages/ovr/phpsa)\n[![License](https://poser.pugx.org/ovr/phpsa/license.svg)](https://packagist.org/packages/ovr/phpsa)\n\n\u003e PHPSA is a development tool aimed at bringing complex analysis for PHP applications and libraries.\n\nP.S This software is currently in early alpha state, any contributions/stars will be awesome.\n\n### Components\n\n- [X] Core - Component containing definitions and other core files\n- [X] Compiler - Component to compile expression(s) and statement(s) from an abstract syntax tree\n- [X] Analyzer - Component doing various checks on your files\n- [X] ControlFlow - Component for ControlFlow (WIP)\n\n### Installation \u003csub\u003e[(more)](/docs/01_Installation.md)\u003c/sub\u003e\n\nThe recommended way to install phpsa is via Composer.\n\nRun `php composer.phar require ovr/phpsa` or add a new requirement in your composer.json.\n\n``` json\n{\n  \"require\": {\n    \"ovr/phpsa\": \"*\"\n  }\n}\n```\n\n### How to use \u003csub\u003e[(more)](/docs/02_Usage.md)\u003c/sub\u003e\n\n```sh\n$ ./bin/phpsa check fixtures/\n\nSyntax error:  Syntax error, unexpected T_RETURN on line 11 in fixtures/simple/syntax/Error2.php \n\n    $b = $a + 1; 123123\n\nNotice:  Constant BBBB does not exist in self scope in fixtures/simple/undefined/Const.php on 29 [undefined-const]\n\n    return self::BBBB; \n\nNotice:  You are trying to cast 'string' to 'string' in fixtures/simple/code-smell/StandardFunctionCall.php on 16 [stupid.cast]\n\n    return (string) json_encode(array(\n\nNotice:  Missing docblock for callStaticMethodBySelf() method in fixtures/Compiling/Expression/StaticCall.php on 18 [missing-docblock]\n\n    public static function callStaticMethodBySelf()\n\n```\n\n\n### Requirements\n\nPHP \u003e= 7.0, but you can check files that use PHP \u003e= 5.2 with this.\n\n### Documentation\n\nSee our [documentation](/docs/) in case you need more information on some topic.\n\n### Contributing\n\nCheck our [Contributing Guide](/.github/CONTRIBUTING.md) to see how you can help.\n\n### Sponsors\n\nThanks to our sponsors and supporters:\n\n| JetBrains |\n|---|\n| \u003ca href=\"https://www.jetbrains.com/phpstorm/\" title=\"PHP IDE :: JetBrains PhpStorm\" target=\"_blank\"\u003e\u003cimg src=\"https://resources.jetbrains.com/assets/media/open-graph/jetbrains_250x250.png\" height=\"55\"\u003e\u003c/img\u003e\u003c/a\u003e |\n\n### LICENSE\n\nThis project is open-sourced software licensed under the MIT License.\n\nSee the [LICENSE](LICENSE) file for more information.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fovr%2Fphpsa","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fovr%2Fphpsa","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fovr%2Fphpsa/lists"}