nixpkgs/home/programs/neovim/nix-plugins/phpactor.nix
Daniel Siepmann a10f010a43
Update phpactor
Also improve performance by ignoring diagnostics.
Remove unused files.
Shorten PATH setting.
Switching to PHP 82 as most recent version.
2023-02-14 08:29:04 +01:00

48 lines
936 B
Nix

{
vimUtils,
fetchurl,
makeWrapper,
lib,
php82,
php82Packages,
git
}:
let
pname = "phpactor";
version = "4e89a6965fdaf42a536b56519c7f2e9fe35f90af";
in vimUtils.buildVimPluginFrom2Nix {
inherit pname version;
src = fetchurl {
url = "https://daniel-siepmann.de/fileadmin/${pname}-${version}.tar.gz";
sha256 = "C548mTIa+J+LsnQPvGU5kKeWQaRizdv+zu0YgJn+wJA=";
};
nativeBuildInputs = [
makeWrapper
];
prePatch = ''
rm -rf .github/ tests/ \
.gitignore \
.php-cs-fixer.dist.php \
CHANGELOG.md \
composer.json \
LICENSE \
Makefile \
phpactor.schema.json \
phpbench.json \
phpstan-baseline.neon \
phpstan.neon \
phpunit.xml.dist \
README.md \
requirements.txt
'';
postInstall = ''
wrapProgram $out/bin/phpactor \
--prefix PATH : ${lib.strings.makeBinPath [ php82 php82Packages.composer git]}
'';
}