Skip to content

Use VSCode Spring Boot Tools from mason-registry #15

Description

@indika-dev

Hi @JavaHello ,

I'm the author of the PR #8077, which adds VSCode Spring Boot Tools from the OpenVSX-Registry to the mason core registry. After taking a closer look on the capabilities of mason, I realized, that I can load and parse the so called mason receipt. This opens the possibility of being completly independent from local installations paths and internal changes inside a VSCode plugin, so that the code to integrate a plugin in Neovim should be more stable over time or at least with minimal changes. That worked very well with java-debug-adapter and java-test and then I decided to integrate your plugin in the same way. In the end, I forked your repo and added the integration for spring_boot.java_extensions() in such a way, that the VSCode Spring Boot Tools can be loaded either from VSCode install path, path given in config or mason-registry. Unfortunately, your code was quite hard to understand for myseld and I started to refactor it, so that I can be sure, I understand that my additions work well with your plugin. The final result of my refactoring has a quite heavy impact on your code (at least in my opinion) and you can see it in PR #14 . I totally understand it, if you say, that this is too much and therefore you deny this PR. But it would be great, if the integration part with mason-registry in this PR could be added to your plugin. You can find this part in spring_boot.[get_ls_from_mason, get_from_mason_registry, setup, java_extensions].


After some time I found out, that @s1n7ax integrates your plugin in his nvim-java plugin and he has a mason-registry on its own and therefore I think, it would be beneficial for his plugin, too, if the mason-registry is integrated in your spring-boot plugin.


To have an idea, what it means, if you use mason receipts to integrate packages provided by mason, you can take a look at my Neovim config for jdtls and your spring-boot plugin:

  • jdtls.lua for loading all relevant integration parts in lines 8-34 and 60-70
  • springBoot.lua for configuring spring-boot.nvim


    @s1n7ax If @JavaHello decides to add my changes to his code, the spring-boot package in your mason registry will be incompatible to the one of the PR #8077. Therefore, I also opened a PR in your mason registry to have the packages compatibel. In this PR is also included a compatibility patch for jdtls, so that anyone can switch seamlessly between the different mason registries without changing the integration code in Neovim. Since you are already using spring_boot.java_extensions() in your plugin, the changes in your code for the new package name should be minimal.


    So, this is a rather complex PR sequence and their consequences, which spans three different mason registries(I patched already my mason registry to be compatibel between nvim-java mason-registry and mason core registry; depending on how this issue will be solved, a PR in mason core registry for adding linux-arm64 target for jdtls has to be opened) , two different git repositories and involves three people. Therefore, I was looking for a single place to discuss this in one place and this place should be this issue. I hope you're all fine with this and I'm eagerly waiting for your feedback. :)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions