mirror of
https://github.com/zap-proto/intellij.git
synced 2026-10-30 15:04:52 +00:00
User-facing identity → ZAP / zap, while staying wire- and library-compatible with Cap'n Proto. - plugin.xml: id org.zapproto.intellij, name ZAP, ZAP vendor/description; language id Capnp→Zap (matches CapnpLanguage), fileType display name Zap file (matches getName); add .zap extension while keeping .capnp associated for back-compat; action texts → ZAP. - CapnpLanguage/CapnpFileType/CapnpColorSettingsPage: language id, file type display name/description, default extension (.zap), color settings page title + demo text → ZAP. - README / build.gradle group / settings.gradle / .iml → ZAP project identity (sercapnp.iml renamed to zap-intellij.iml). Preserved: com.sercapnp.* Java package + Capnp* class names and the implementationClass/class/flex targetClass identifiers the build depends on; the .capnp extension; and Cap'n Proto attribution (capnproto.org).
62 lines
1.5 KiB
Groovy
62 lines
1.5 KiB
Groovy
import org.jetbrains.grammarkit.tasks.GenerateLexerTask
|
|
|
|
plugins {
|
|
id 'java'
|
|
id 'org.jetbrains.intellij' version '1.17.4'
|
|
id 'org.jetbrains.grammarkit' version '2021.2.1'
|
|
}
|
|
|
|
group 'org.zapproto'
|
|
version '2.0'
|
|
|
|
java {
|
|
sourceCompatibility = JavaVersion.VERSION_11
|
|
targetCompatibility = JavaVersion.VERSION_11
|
|
}
|
|
|
|
repositories {
|
|
mavenCentral()
|
|
}
|
|
|
|
dependencies {
|
|
testImplementation 'junit:junit:4.13.2'
|
|
}
|
|
|
|
intellij {
|
|
version.set('2022.1.4')
|
|
type.set('IC')
|
|
}
|
|
|
|
patchPluginXml {
|
|
sinceBuild.set('221')
|
|
untilBuild.set('')
|
|
changeNotes.set("""
|
|
<ul>
|
|
<li>Updated for IntelliJ Platform 2022.1+ compatibility</li>
|
|
<li>Support for all modern JetBrains IDEs (2022-2025)</li>
|
|
<li>Fixed syntax highlighter registration issue</li>
|
|
<li>Bug fixes and compatibility improvements</li>
|
|
</ul>
|
|
""")
|
|
}
|
|
|
|
tasks.withType(JavaCompile) {
|
|
options.encoding = 'UTF-8'
|
|
}
|
|
|
|
task cleanLexer(type: Delete) {
|
|
delete file('build/generated-src/com/sercapnp/lang/CapnpLexer.java')
|
|
}
|
|
|
|
tasks.named('generateLexer', GenerateLexerTask).configure { task ->
|
|
task.source = 'src/main/java/com/sercapnp/lang/Capnp.flex'
|
|
task.targetDir = 'build/generated-src/com/sercapnp/lang'
|
|
task.targetClass = 'CapnpLexer'
|
|
task.purgeOldFiles = true
|
|
}
|
|
|
|
sourceSets.main.java.srcDir layout.buildDirectory.dir('generated-src')
|
|
|
|
tasks.named('generateLexer').configure { it.dependsOn cleanLexer }
|
|
tasks.named('compileJava').configure { it.dependsOn tasks.named('generateLexer') }
|