Use upstream phpactor
phpactor was added to upstream. This only included the lsp usable package, not vim plugin. I no longer need my own build script as I now use the upstream version. That way I benefit from all the maintenance and updates. I use the package source to build the neovim plugin.
This commit is contained in:
parent
6402359d3a
commit
bd6c8adb7f
|
@ -1,32 +0,0 @@
|
||||||
{
|
|
||||||
writeShellApplication,
|
|
||||||
php82,
|
|
||||||
php82Packages,
|
|
||||||
git
|
|
||||||
}:
|
|
||||||
|
|
||||||
writeShellApplication {
|
|
||||||
name = "custom-build-phpactor";
|
|
||||||
|
|
||||||
runtimeInputs = [
|
|
||||||
php82
|
|
||||||
php82Packages.composer
|
|
||||||
git
|
|
||||||
];
|
|
||||||
|
|
||||||
# TODO: Use nix build environment?!
|
|
||||||
text = ''
|
|
||||||
rm -rf /tmp/phpactor
|
|
||||||
mkdir /tmp/phpactor
|
|
||||||
cd /tmp/phpactor
|
|
||||||
git clone --depth 1 https://github.com/phpactor/phpactor.git .
|
|
||||||
composer install -o --no-dev
|
|
||||||
version=$(git show -s --format=%H)
|
|
||||||
rm -rf .git/
|
|
||||||
cd /tmp
|
|
||||||
tar -czf "phpactor-$version.tar.gz" phpactor
|
|
||||||
rsync -vaz "phpactor-$version.tar.gz" daniel-siepmann.de:webs/daniel-siepmann.de/htdocs/public/fileadmin/
|
|
||||||
cd /tmp
|
|
||||||
rm -rf /tmp/phpactor "phpactor-$version.tar.gz"
|
|
||||||
'';
|
|
||||||
}
|
|
|
@ -9,7 +9,6 @@
|
||||||
(callPackage ./nextcloud-sync/from-local.nix { })
|
(callPackage ./nextcloud-sync/from-local.nix { })
|
||||||
(callPackage ./nextcloud-sync/from-remote.nix { })
|
(callPackage ./nextcloud-sync/from-remote.nix { })
|
||||||
(callPackage ./typo3-documentation-rendering { })
|
(callPackage ./typo3-documentation-rendering { })
|
||||||
(callPackage ./build-phpactor { })
|
|
||||||
(callPackage ./project {
|
(callPackage ./project {
|
||||||
inherit ownLib;
|
inherit ownLib;
|
||||||
})
|
})
|
||||||
|
|
|
@ -308,7 +308,7 @@ in {
|
||||||
|
|
||||||
require('lspconfig').phpactor.setup({
|
require('lspconfig').phpactor.setup({
|
||||||
cmd = {
|
cmd = {
|
||||||
'${phpactor}/bin/phpactor',
|
'${pkgs.phpactor}/bin/phpactor',
|
||||||
'language-server',
|
'language-server',
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
|
@ -1,22 +1,18 @@
|
||||||
{
|
{
|
||||||
vimUtils,
|
vimUtils
|
||||||
fetchurl,
|
, makeWrapper
|
||||||
makeWrapper,
|
, lib
|
||||||
lib,
|
, phpactor
|
||||||
php82,
|
, php82
|
||||||
php82Packages,
|
, php82Packages
|
||||||
git
|
, git
|
||||||
}:
|
}:
|
||||||
|
|
||||||
let
|
vimUtils.buildVimPluginFrom2Nix rec {
|
||||||
pname = "phpactor";
|
inherit (phpactor) version;
|
||||||
version = "3e7cb48b0ca429f92bcd57c236c39f170e9d23b1";
|
|
||||||
in vimUtils.buildVimPluginFrom2Nix {
|
pname = "vim-phpactor";
|
||||||
inherit pname version;
|
src = "${phpactor}/share/php/phpactor";
|
||||||
src = fetchurl {
|
|
||||||
url = "https://daniel-siepmann.de/fileadmin/${pname}-${version}.tar.gz";
|
|
||||||
sha256 = "JX6aLuzmJ4rrcG0FNgzt2zITmnRrpitUI591oPn+fhY=";
|
|
||||||
};
|
|
||||||
|
|
||||||
nativeBuildInputs = [
|
nativeBuildInputs = [
|
||||||
makeWrapper
|
makeWrapper
|
||||||
|
@ -39,7 +35,6 @@ in vimUtils.buildVimPluginFrom2Nix {
|
||||||
requirements.txt
|
requirements.txt
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
|
||||||
postInstall = ''
|
postInstall = ''
|
||||||
wrapProgram $out/bin/phpactor \
|
wrapProgram $out/bin/phpactor \
|
||||||
--prefix PATH : ${lib.strings.makeBinPath [ php82 php82Packages.composer git]}
|
--prefix PATH : ${lib.strings.makeBinPath [ php82 php82Packages.composer git]}
|
||||||
|
|
Loading…
Reference in a new issue