phpactor: add shell completion
Shell completions are only provided for bash. This means they will also work for zsh, but not for fish
This commit is contained in:
parent
0acec5c64d
commit
7690776867
1 changed files with 8 additions and 0 deletions
|
@ -1,5 +1,6 @@
|
|||
{ lib
|
||||
, fetchFromGitHub
|
||||
, installShellFiles
|
||||
, php
|
||||
}:
|
||||
|
||||
|
@ -16,6 +17,13 @@ php.buildComposerProject (finalAttrs: {
|
|||
|
||||
vendorHash = "sha256-0jvWbQubPXDhsXqEp8q5R0Y7rQX3UiccGDF3HDBeh7o=";
|
||||
|
||||
nativeBuildInputs = [ installShellFiles ];
|
||||
|
||||
postInstall = ''
|
||||
installShellCompletion --cmd phpactor \
|
||||
--bash <($out/bin/phpactor completion bash)
|
||||
'';
|
||||
|
||||
meta = {
|
||||
changelog = "https://github.com/phpactor/phpactor/releases/tag/${finalAttrs.version}";
|
||||
description = "Mainly a PHP Language Server";
|
||||
|
|
Loading…
Reference in a new issue