-
Notifications
You must be signed in to change notification settings - Fork 111
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create Visual Studio Code extension #142
Conversation
Sadly it doesn't compile to me using ./mvnw clean package on the root of the repository:
|
Hi @snicoll, is there any plan to merge this? |
@cirelli94 I don't know. We're lacking time to review this one and make up our mind about it, sorry. |
Any updates on this? Can't seem to find a decentformatter/validator that integrates nicely with VS Code and Maven. Google Style Guide, Spring Java Format and others do not handle lambdas good enough. Palantir is an alternative but spotless VS Code extension is based on gradle (we use maven). |
I'm afraid not. We do not use vscode so it's difficult to find the time to review the proposal.
This confuses me a little. If you don't like how Spring Java Format handles lambdas why are you interested in its integration with vscode? |
Regarding the review, ok I understand. Not trying to confuse you on purpose but I can see that :) We have to decide on something and VS Code integration is a deciding factor. It could also be that we could use Spring Java Format as a baseline for an lambda adaption. |
@wilkinsona With the updates on #124 spring-javaformat would fit our needs. Our team uses VS Code. Is there anything I/we can do to assist with this PR, e.g. test? |
@leftstick Would it be possible for you to update this PR to match the latest on main? I would gladly test it afterwards if needed. UPDATE: I tried building this PR but it failed due to an issue with an Eclipse repo. I therefore merged the latest origin/main into this PR. There where two minor conflicts (.gitignore and a README) that were easily resolved. Trying to build it now again. Having issues with connections. Suspecting our company proxy. Will try from private computer later. |
I've rebased the PR onto the latest |
@philwebb Thank you! Please let me know if I can assist in any way. |
Add Visual Studio Code extension to apply spring-javaformat conventions. See gh-142
Refine extension to use stdin/stdout to communicate with the Java code rather than using an HTTP endpoint. This commit also restructures the way that the extension is built and reduces the number of Maven projects. It also drops Markdown formatting support. See gh-142
Thanks very much for the PR @leftstick. I've merged this into We don't have a lot of vscode expertise in the team, so we're going to need to rely on the community quite a bit for this extension. If anyone watching the issue wants to kick the tires the SNAPSHOT release is available at https://repo.spring.io/ui/native/snapshot/io/spring/javaformat/spring-javaformat-vscode-extension/0.0.36-SNAPSHOT/ |
@leftstick @philwebb Thank you very much. I just installed the extension and so far, so good. @leftstick How much work would it be to upload it to the VS Code Extension Market place (here)? And is that something that the Spring team would approve? It would make it a lot easier to adopt and also the risk of having a mismatch between versions (Maven and VS Code) is reduced greatly. I spotted a small error with a link here, see DocumentFormattingEditProvider. |
@lfvjimisola it is quick simple to publish the extension to vscode market place, you will refer to the guide publish-extension. |
Thanks! Fixed that one now. |
If we want to publish the extension I think we should do it as part of our CI release process. For now, I suggest we try the manual install approach to make sure the extension works as expected. |
@philwebb Yes, I agree. My thought was not to set it up now but rather curious on how much work it would be. We'll make sure to try it properly manually before adding it to CI release process. |
implement vscode extension, see below: