mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 23:13:19 +00:00
phpPackages.phpstan: Move to separate directory
This commit is contained in:
parent
b3f36d7cd7
commit
2defaa83c0
37
pkgs/development/php-packages/phpstan/default.nix
Normal file
37
pkgs/development/php-packages/phpstan/default.nix
Normal file
@ -0,0 +1,37 @@
|
||||
{ mkDerivation, fetchurl, pkgs, lib, php }:
|
||||
let
|
||||
pname = "phpstan";
|
||||
version = "0.12.48";
|
||||
in
|
||||
mkDerivation {
|
||||
inherit pname version;
|
||||
|
||||
src = pkgs.fetchurl {
|
||||
url = "https://github.com/phpstan/phpstan/releases/download/${version}/phpstan.phar";
|
||||
sha256 = "170yzz23lyipyckv8y2x9masv5qdmbskwwlbfc8750xb3g2q7pzl";
|
||||
};
|
||||
|
||||
phases = [ "installPhase" ];
|
||||
nativeBuildInputs = [ pkgs.makeWrapper ];
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin
|
||||
install -D $src $out/libexec/phpstan/phpstan.phar
|
||||
makeWrapper ${php}/bin/php $out/bin/phpstan \
|
||||
--add-flags "$out/libexec/phpstan/phpstan.phar"
|
||||
'';
|
||||
|
||||
meta = with pkgs.lib; {
|
||||
description = "PHP Static Analysis Tool";
|
||||
longDescription = ''
|
||||
PHPStan focuses on finding errors in your code without actually
|
||||
running it. It catches whole classes of bugs even before you write
|
||||
tests for the code. It moves PHP closer to compiled languages in the
|
||||
sense that the correctness of each line of the code can be checked
|
||||
before you run the actual line.
|
||||
'';
|
||||
license = licenses.mit;
|
||||
homepage = "https://github.com/phpstan/phpstan";
|
||||
maintainers = teams.php.members;
|
||||
};
|
||||
}
|
@ -49,39 +49,7 @@ in
|
||||
|
||||
phpmd = callPackage ../development/php-packages/phpmd { };
|
||||
|
||||
phpstan = mkDerivation rec {
|
||||
version = "0.12.48";
|
||||
pname = "phpstan";
|
||||
|
||||
src = pkgs.fetchurl {
|
||||
url = "https://github.com/phpstan/phpstan/releases/download/${version}/phpstan.phar";
|
||||
sha256 = "170yzz23lyipyckv8y2x9masv5qdmbskwwlbfc8750xb3g2q7pzl";
|
||||
};
|
||||
|
||||
phases = [ "installPhase" ];
|
||||
nativeBuildInputs = [ pkgs.makeWrapper ];
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin
|
||||
install -D $src $out/libexec/phpstan/phpstan.phar
|
||||
makeWrapper ${php}/bin/php $out/bin/phpstan \
|
||||
--add-flags "$out/libexec/phpstan/phpstan.phar"
|
||||
'';
|
||||
|
||||
meta = with pkgs.lib; {
|
||||
description = "PHP Static Analysis Tool";
|
||||
longDescription = ''
|
||||
PHPStan focuses on finding errors in your code without actually
|
||||
running it. It catches whole classes of bugs even before you write
|
||||
tests for the code. It moves PHP closer to compiled languages in the
|
||||
sense that the correctness of each line of the code can be checked
|
||||
before you run the actual line.
|
||||
'';
|
||||
license = licenses.mit;
|
||||
homepage = "https://github.com/phpstan/phpstan";
|
||||
maintainers = teams.php.members;
|
||||
};
|
||||
};
|
||||
phpstan = callPackage ../development/php-packages/phpstan { };
|
||||
|
||||
psalm = mkDerivation rec {
|
||||
version = "3.11.2";
|
||||
|
Loading…
Reference in New Issue
Block a user