Skip to content
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

Build the server locally #1

Closed
XiaowenHu96 opened this issue Nov 6, 2022 · 3 comments
Closed

Build the server locally #1

XiaowenHu96 opened this issue Nov 6, 2022 · 3 comments

Comments

@XiaowenHu96
Copy link

I want to use the language server with vim, is there any way I can build the project locally?

I have no experience with Gradle-based projects and had no luck with gradle build or gradlew wrapper.

* What went wrong:
Could not open settings generic class cache for settings file '/home/xiaowen/souffle-lsp-plugin/settings.gradle' (/home/xiaowen/.gradle/caches/7.5.1/scripts/1lepdxfcl23lx79rdpsew90n).
> BUG! exception in phase 'semantic analysis' in source unit '_BuildScript_' Unsupported class file major version 63

* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 325ms

gradle --version:


------------------------------------------------------------
Gradle 7.5.1
------------------------------------------------------------

Build time:   2022-08-06 13:53:45 UTC
Revision:     <unknown>

Kotlin:       1.6.21
Groovy:       3.0.10
Ant:          Apache Ant(TM) version 1.10.11 compiled on July 10 2021
JVM:          19.0.1 (Oracle Corporation 19.0.1+10)
OS:           Linux 5.19.7-arch1-1 amd64
@jdaridis
Copy link
Owner

jdaridis commented Nov 6, 2022

There is no need to build the server yourself. The process is already complete, but I had the resulting jar under .gitignore, oops. Now it is visible.

To integrate the server with a client you need to set up a script running .jar file as I do for the VS code extension in https://github.com/jdaridis/souffle-lsp-plugin/blob/master/src/main/vs-code/extension.ts line 74-79.
For Vim I imagine there is a similar process, you have to write a script for vim to know when it detects a .dl file to run the .jar file. From a quick Google search, I see that the Vim team has good documentation on how to implement the client side

@XiaowenHu96
Copy link
Author

Thanks for the clear instruction, I'll give it a try and get back to you next week.

@jdaridis
Copy link
Owner

jdaridis commented Nov 6, 2022

I added the jar file as a release to make it easier to find.

Also for completeness, to build the java source code run ./gradlew jar on the top level.
I updated the README file with more instructions on how to build and run the standalone server.

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

No branches or pull requests

2 participants