Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

PHP roots and languageserver improvements #2031

Merged
merged 1 commit into from
Apr 8, 2022

Conversation

grasegger
Copy link
Contributor

@grasegger grasegger commented Apr 8, 2022

Hello,

this pull request adds two things to the default languages.toml:

Setting the default lsp to intelephense

After a lot of testing of different lsp implementations for php I found intelephense to be the best one for my projects (laravel, TYPO3, Wordpress). The free version offers a lot of value and the professional version is very affordable (15€). I understand that it can be controversial depending on a paid product for full functionality as an open source project, but as a developer I also value tools that save my time.

Defining roots

I added composer.json (composer is the de facto standard package manager for PHP) and index.php (still the default entry point for all modern projects) as workspace roots.

@the-mikedavis
Copy link
Member

I understand that it can be controversial depending on a paid product for full functionality as an open source project

IMO this is not a big deal since it is easy for someone to override this setting in their own languages.toml if they want to use any other language server, e.g.:

# on unix: ~/.config/helix/languages.toml
[[language]]
name = "php"
language-server = { command = "some-foss-php-ls" }

I think

as a developer I also value tools that save my time

is very reasonable :)

@David-Else
Copy link
Contributor

When I tried all the different PHP language servers I also found that the free intelephense was by far the best!

Copy link
Member

@the-mikedavis the-mikedavis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks!

@the-mikedavis the-mikedavis merged commit 8e12fd5 into helix-editor:master Apr 8, 2022
@David-Else
Copy link
Contributor

I added intelephense https://github.com/helix-editor/helix/wiki/How-to-install-the-default-language-servers#intelephense to the WIKI

@grasegger
Copy link
Contributor Author

I added intelephense https://github.com/helix-editor/helix/wiki/How-to-install-the-default-language-servers#intelephense to the WIKI

Thanks, I was not aware of that page, it probably should be part of the docs? 🤔

@the-mikedavis
Copy link
Member

Ah yep, we should probably link to that from the readme and maybe the docs here

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants