WIP WIP WIP lsp support
This commit is contained in:
parent
f2220b7546
commit
971bf5dbc1
6 changed files with 52 additions and 5 deletions
|
@ -11,7 +11,10 @@ plugins {
|
||||||
idea
|
idea
|
||||||
}
|
}
|
||||||
|
|
||||||
val javaVersion = providers.gradleProperty("javaVersion").get().toInt()
|
val javaVersion = property("javaVersion").toString().toInt()
|
||||||
|
val lsp4ijVersion: String by project
|
||||||
|
val lsp4ijNightly = property("lsp4ijNightly").toString().toBoolean()
|
||||||
|
val lsp4ijPluginString = "com.redhat.devtools.lsp4ij:$lsp4ijVersion${if (lsp4ijNightly) "@nightly" else ""}"
|
||||||
|
|
||||||
group = "com.falsepattern"
|
group = "com.falsepattern"
|
||||||
version = providers.gradleProperty("pluginVersion").get()
|
version = providers.gradleProperty("pluginVersion").get()
|
||||||
|
@ -74,10 +77,12 @@ dependencies {
|
||||||
|
|
||||||
pluginVerifier()
|
pluginVerifier()
|
||||||
zipSigner()
|
zipSigner()
|
||||||
|
plugin(lsp4ijPluginString)
|
||||||
}
|
}
|
||||||
|
|
||||||
implementation(project(":zig"))
|
implementation(project(":zig"))
|
||||||
implementation(project(":zon"))
|
implementation(project(":zon"))
|
||||||
|
implementation(project(":lsp"))
|
||||||
}
|
}
|
||||||
|
|
||||||
intellijPlatform {
|
intellijPlatform {
|
||||||
|
|
|
@ -9,6 +9,10 @@ pluginUntilBuild =
|
||||||
ideaCommunityVersion = 2024.2.4
|
ideaCommunityVersion = 2024.2.4
|
||||||
javaVersion=21
|
javaVersion=21
|
||||||
|
|
||||||
|
lsp4jVersion=0.21.1
|
||||||
|
lsp4ijVersion=0.7.0
|
||||||
|
lsp4ijNightly=false
|
||||||
|
|
||||||
kotlin.stdlib.default.dependency = false
|
kotlin.stdlib.default.dependency = false
|
||||||
kotlin.code.style=official
|
kotlin.code.style=official
|
||||||
org.gradle.configuration-cache = true
|
org.gradle.configuration-cache = true
|
||||||
|
|
14
modules/lsp/build.gradle.kts
Normal file
14
modules/lsp/build.gradle.kts
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
import org.jetbrains.intellij.platform.gradle.IntelliJPlatformType
|
||||||
|
|
||||||
|
val lsp4ijVersion: String by project
|
||||||
|
val lsp4jVersion: String by project
|
||||||
|
val lsp4ijNightly = property("lsp4ijNightly").toString().toBoolean()
|
||||||
|
val lsp4ijDepString = "${if (lsp4ijNightly) "nightly." else ""}com.jetbrains.plugins:com.redhat.devtools.lsp4ij:$lsp4ijVersion"
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
intellijPlatform {
|
||||||
|
create(IntelliJPlatformType.IntellijIdeaCommunity, providers.gradleProperty("ideaCommunityVersion"))
|
||||||
|
}
|
||||||
|
intellijPlatformPluginDependency(lsp4ijDepString)
|
||||||
|
compileOnly("org.eclipse.lsp4j:org.eclipse.lsp4j:$lsp4jVersion")
|
||||||
|
}
|
|
@ -0,0 +1,4 @@
|
||||||
|
package com.falsepattern.zigbrains.lsp
|
||||||
|
|
||||||
|
class ZigLanguageServerFactory {
|
||||||
|
}
|
|
@ -0,0 +1,20 @@
|
||||||
|
package com.falsepattern.zigbrains.lsp
|
||||||
|
|
||||||
|
import com.intellij.openapi.diagnostic.Logger
|
||||||
|
import com.intellij.openapi.project.Project
|
||||||
|
import com.redhat.devtools.lsp4ij.server.OSProcessStreamConnectionProvider
|
||||||
|
|
||||||
|
class ZigStreamConnectionProvider(private val project: Project): OSProcessStreamConnectionProvider() {
|
||||||
|
init {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
companion object {
|
||||||
|
private val LOG = Logger.getInstance(ZigStreamConnectionProvider::class.java)
|
||||||
|
|
||||||
|
suspend fun getCommand(project: Project, full: Boolean) {
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
|
@ -3,7 +3,7 @@ plugins {
|
||||||
}
|
}
|
||||||
rootProject.name = "ZigBrains"
|
rootProject.name = "ZigBrains"
|
||||||
|
|
||||||
include("zig")
|
for (module in arrayOf("zig", "zon", "lsp")) {
|
||||||
project(":zig").projectDir = file("modules/zig")
|
include(module)
|
||||||
include("zon")
|
project(":$module").projectDir = file("modules/$module")
|
||||||
project(":zon").projectDir = file("modules/zon")
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue