nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at flake-libs 41 lines 1.2 kB view raw
1{ 2 fetchFromGitHub, 3 lib, 4 php, 5 versionCheckHook, 6}: 7 8php.buildComposerProject2 (finalAttrs: { 9 pname = "phpstan"; 10 version = "2.1.17"; 11 12 src = fetchFromGitHub { 13 owner = "phpstan"; 14 repo = "phpstan-src"; 15 tag = finalAttrs.version; 16 hash = "sha256-F4K+9tmnonUdk7VtXVo0tYf4RgoNjzGmIteWkzMOkYE="; 17 }; 18 19 vendorHash = "sha256-q83Gb2oujougRQVmeTOtdnVtP4IRghPUpo1kzbSlhiQ="; 20 composerStrictValidation = false; 21 22 doInstallCheck = true; 23 nativeInstallCheckInputs = [ versionCheckHook ]; 24 versionCheckProgramArg = "--version"; 25 26 meta = { 27 changelog = "https://github.com/phpstan/phpstan/releases/tag/${finalAttrs.version}"; 28 description = "PHP Static Analysis Tool"; 29 homepage = "https://github.com/phpstan/phpstan"; 30 longDescription = '' 31 PHPStan focuses on finding errors in your code without actually 32 running it. It catches whole classes of bugs even before you write 33 tests for the code. It moves PHP closer to compiled languages in the 34 sense that the correctness of each line of the code can be checked 35 before you run the actual line. 36 ''; 37 license = lib.licenses.mit; 38 mainProgram = "phpstan"; 39 teams = [ lib.teams.php ]; 40 }; 41})