1
0
mirror of https://github.com/chylex/IntelliJ-Rainbow-Brackets.git synced 2026-06-14 16:02:29 +02:00

Compare commits

..

4 Commits

20 changed files with 569 additions and 689 deletions

1
.gitignore vendored
View File

@@ -2,5 +2,6 @@
!/.idea/runConfigurations
/.gradle/
/.kotlin/
/.intellijPlatform/
/build/

View File

@@ -18,7 +18,6 @@ dependencies {
bundledPlugin("org.jetbrains.kotlin")
bundledPlugin("org.jetbrains.plugins.yaml")
compatiblePlugin("Dart")
compatiblePlugin("PythonCore")
compatiblePlugin("com.jetbrains.php")
compatiblePlugin("com.jetbrains.plugins.jade")
@@ -27,6 +26,8 @@ dependencies {
compatiblePlugin("org.jetbrains.plugins.go-template")
compatiblePlugin("org.jetbrains.plugins.ruby")
plugin("Dart:504.0.0") // https://plugins.jetbrains.com/plugin/6351-dart/versions/stable
testFramework(TestFrameworkType.Platform)
testFramework(TestFrameworkType.Plugin.Java)
testFramework(TestFrameworkType.Plugin.JavaScript)
@@ -38,3 +39,7 @@ dependencies {
excludeCoroutines()
}
}
intellijPlatform {
buildSearchableOptions = true
}

View File

@@ -22,10 +22,7 @@ void main() {
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
roundLevel(0),
angleLevel(0),

View File

@@ -22,10 +22,7 @@ Map<String, Map<String, String>> convertObjectsToMapProperties(Map<String, Objec
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
angleLevel(0),
angleLevel(1),

View File

@@ -1,7 +1,7 @@
package com.chylex.intellij.coloredbrackets
import com.intellij.ide.plugins.PluginManagerCore
import com.intellij.lang.ecmascript6.JSXHarmonyFileType
import com.intellij.lang.javascript.JSXFileType
import com.intellij.lang.javascript.JavaScriptFileType
import com.intellij.lang.javascript.TypeScriptFileType
import com.intellij.openapi.extensions.PluginId
@@ -24,14 +24,11 @@ const _ = require('lodash') || false
const moment = require('moment')
""".trimIndent()
myFixture.configureByText(JavaScriptFileType.INSTANCE, code)
myFixture.configureByText(JavaScriptFileType, code)
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
roundLevel(0),
roundLevel(0),
@@ -47,14 +44,11 @@ const moment = require('moment')
console.log(a > b)
console.log(a == b)
""".trimIndent()
myFixture.configureByText(JavaScriptFileType.INSTANCE, code)
myFixture.configureByText(JavaScriptFileType, code)
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
roundLevel(0),
roundLevel(0),
@@ -68,14 +62,11 @@ console.log(a == b)
@Language("JavaScript") val code = "open (\$" + "{f})\n" + "open (\$" + "{f} )"
myFixture.configureByText(JavaScriptFileType.INSTANCE, code)
myFixture.configureByText(JavaScriptFileType, code)
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
roundLevel(0),
roundLevel(0),
@@ -102,14 +93,11 @@ if ((a.field_detail && a.is) ||
""".trimIndent()
myFixture.configureByText(JavaScriptFileType.INSTANCE, code)
myFixture.configureByText(JavaScriptFileType, code)
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
roundLevel(0),
roundLevel(1),
@@ -136,15 +124,11 @@ if ((a.field_detail && a.is) ||
const element = ( <div> <h1>Hello, world!</h1> </div> );
""".trimIndent()
myFixture.configureByText(JSXHarmonyFileType.INSTANCE, code)
myFixture.configureByText(JSXFileType, code)
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.filterNot { it == null }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
roundLevel(0),
@@ -167,15 +151,11 @@ const element = ( <div> <h1>Hello, world!</h1> </div> );
const html = '<div><div><div>Hello</div></div></div>'
""".trimIndent()
myFixture.configureByText(JavaScriptFileType.INSTANCE, code)
myFixture.configureByText(JavaScriptFileType, code)
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.filterNot { it == null }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
angleLevel(0),
angleLevel(0),
@@ -201,24 +181,20 @@ const element = ( <div> <h1>Hello, world!</h1> </div> );
const s = `<ololo>`
""".trimIndent()
myFixture.configureByText(TypeScriptFileType.INSTANCE, code)
myFixture.configureByText(TypeScriptFileType, code)
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.filterNot { it == null }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
roundLevel(0),
roundLevel(0),
squigglyLevel(0),
squigglyLevel(0),
squareLevel(0),
squareLevel(0)
//, angleLevel(0)
//, angleLevel(0)
squareLevel(0),
angleLevel(0),
angleLevel(0)
)
)
}
@@ -226,15 +202,11 @@ const element = ( <div> <h1>Hello, world!</h1> </div> );
fun testIssue427() {
@Language("TypeScript") val code = """let example: Array<Map<string,string>>;""".trimIndent()
myFixture.configureByText(TypeScriptFileType.INSTANCE, code)
myFixture.configureByText(TypeScriptFileType, code)
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.filterNot { it == null }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
angleLevel(0),
angleLevel(1),

View File

@@ -35,10 +35,7 @@ public class Test<T> {
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
angleLevel(0),
angleLevel(0),
@@ -75,10 +72,7 @@ public class Test<T> {
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf()
)
}
@@ -98,10 +92,7 @@ public class Test<T> {
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
squigglyLevel(0),
roundLevel(0),
@@ -136,10 +127,7 @@ public class Test<T> {
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
angleLevel(0),
angleLevel(0),
@@ -166,10 +154,7 @@ public class Test<T> {
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
angleLevel(0),
angleLevel(0),
@@ -202,10 +187,7 @@ public class Test<T> {
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
angleLevel(0),
angleLevel(0),
@@ -239,11 +221,7 @@ public class Test<T> {
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.size
.shouldBe(0)
doHighlighting.getBrackets().size.shouldBe(0)
}
fun testIssue391() {
@@ -262,10 +240,7 @@ public class Test {
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
roundLevel(0),//{

View File

@@ -20,10 +20,7 @@ fun <T> filter(l: List<T>, f: (T) -> Boolean): MutableList<T> {
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
angleLevel(0),
angleLevel(0),
@@ -79,35 +76,22 @@ val a: (Int) -> Unit = { aa ->
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting
.filter { brackets.contains(it.text.toChar()) || it.text.contains("->") }
.filter { it?.forcedTextAttributesKey?.defaultAttributes != null }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
roundLevel(0),
roundLevel(0),
squigglyLevel(0),
squigglyLevel(0),
roundLevel(0),
roundLevel(0),
squigglyLevel(1),
squigglyLevel(1),
roundLevel(0),
roundLevel(0),
squigglyLevel(2),
squigglyLevel(2),
roundLevel(0),
roundLevel(0),
squigglyLevel(3),
squigglyLevel(3),
squigglyLevel(3),
@@ -142,11 +126,7 @@ class AA {
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting
.filter { it.forcedTextAttributes != null && it.text.contains("@") }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
squigglyLevel(3),
squigglyLevel(4),
@@ -171,18 +151,13 @@ fun t() {
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting
.filter { brackets.contains(it.text.toChar()) }
.filter { it?.forcedTextAttributesKey?.defaultAttributes != null }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
roundLevel(0),
roundLevel(0),
squigglyLevel(0),
//squigglyLevel(1),
//squigglyLevel(1),
squigglyLevel(1),
squigglyLevel(1),
squigglyLevel(0)
)
)

View File

@@ -1,6 +1,5 @@
package com.chylex.intellij.coloredbrackets
import com.intellij.codeInsight.daemon.impl.HighlightInfoType
import com.intellij.psi.PsiDocumentManager
import com.intellij.testFramework.fixtures.LightJavaCodeInsightFixtureTestCase
import com.jetbrains.php.lang.PhpFileType
@@ -28,10 +27,7 @@ function padZero(string data): string
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) && it.severity != HighlightInfoType.INJECTED_FRAGMENT_SEVERITY }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
roundLevel(0),
roundLevel(0),

View File

@@ -23,11 +23,8 @@ end
myFixture.configureByText(RubyFileType.RUBY, code)
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
assertFalse(doHighlighting.isEmpty());
doHighlighting.getBrackets().shouldBe(
arrayOf(
roundLevel(0),
roundLevel(1),
@@ -45,11 +42,8 @@ foobar(p1: "", p2: false, p3: 1)
myFixture.configureByText(RubyFileType.RUBY, code)
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
assertFalse(doHighlighting.isEmpty());
doHighlighting.getBrackets().shouldBe(
arrayOf(
roundLevel(0),
roundLevel(0)
@@ -71,12 +65,7 @@ end
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting
.filter { brackets.contains(it.text.toChar()) }
.filterNot { it?.forcedTextAttributesKey?.defaultAttributes == null }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
roundLevel(0),
squigglyLevel(0),
@@ -109,12 +98,7 @@ end
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting
.filter { brackets.contains(it.text.toChar()) }
.filterNot { it?.forcedTextAttributesKey?.defaultAttributes == null }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
squareLevel(0),
squareLevel(0),
@@ -135,12 +119,7 @@ end
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting
.filter { brackets.contains(it.text.toChar()) }
.filterNot { it?.forcedTextAttributesKey?.defaultAttributes == null }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
squareLevel(0),
squareLevel(1),

View File

@@ -6,7 +6,9 @@ import com.intellij.testFramework.fixtures.LightJavaCodeInsightFixtureTestCase
import io.kotest.matchers.shouldBe
import org.intellij.lang.annotations.Language
import org.jetbrains.plugins.scala.ScalaFileType
import org.junit.Ignore
@Ignore("IDEA has broken modularization")
class RainbowScalaTest : LightJavaCodeInsightFixtureTestCase() {
override fun tearDown() {
@@ -36,11 +38,7 @@ import scala.annotation.tailrec
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.filter { it?.forcedTextAttributesKey != null }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
squareLevel(0),
squareLevel(0),
@@ -78,11 +76,7 @@ import scala.annotation.tailrec
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting.filter { brackets.contains(it.text.toChar()) }
.filter { it?.forcedTextAttributesKey != null }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
roundLevel(0),

View File

@@ -28,10 +28,7 @@ class RainbowXMLTest : LightJavaCodeInsightFixtureTestCase() {
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
angleLevel(0),
angleLevel(0),
@@ -103,10 +100,7 @@ class RainbowXMLTest : LightJavaCodeInsightFixtureTestCase() {
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
doHighlighting
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.shouldBe(
doHighlighting.getBrackets().shouldBe(
arrayOf(
angleLevel(0),
angleLevel(0),

View File

@@ -25,11 +25,7 @@ public class Test<T> {
PsiDocumentManager.getInstance(project).commitAllDocuments()
val doHighlighting = myFixture.doHighlighting()
assertFalse(doHighlighting.isEmpty())
val highlightSize = doHighlighting.filter { brackets.contains(it.text.toChar()) }
.filter { it.forcedTextAttributesKey.defaultAttributes.foregroundColor != null }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
.size
val highlightSize = doHighlighting.getBrackets().size
assert(highlightSize == 16)
}

View File

@@ -1,8 +1,15 @@
package com.chylex.intellij.coloredbrackets
val brackets = RainbowHighlighter.getBrackets()
import com.chylex.intellij.coloredbrackets.visitor.RainbowHighlightVisitor
import com.intellij.codeInsight.daemon.impl.HighlightInfo
import java.awt.Color
fun CharSequence.toChar() = elementAt(0)
fun List<HighlightInfo>.getBrackets(): Array<Color> {
return this
.filter { it.toolId?.let { id -> id is Class<*> && RainbowHighlightVisitor::class.java.isAssignableFrom(id) } == true }
.map { it.forcedTextAttributesKey.defaultAttributes.foregroundColor }
.toTypedArray()
}
fun roundLevel(level: Int) = RainbowHighlighter.getRainbowColor(RainbowHighlighter.NAME_ROUND_BRACKETS, level)

View File

@@ -27,6 +27,10 @@ allprojects {
}
intellijPlatform {
sandboxContainer.set(layout.buildDirectory.map { it.dir("idea-sandbox") })
buildSearchableOptions = false
pluginConfiguration {
ideaVersion {
sinceBuild.set("253")
@@ -46,14 +50,9 @@ allprojects {
}
}
subprojects {
intellijPlatform {
buildSearchableOptions = false
}
}
idea {
module {
excludeDirs.add(file(".kotlin"))
excludeDirs.add(file("build"))
excludeDirs.add(file("gradle"))
}

View File

@@ -3,6 +3,8 @@ val ideaVersion: String by project
dependencies {
implementation(project(":base"))
runtimeOnly(project(":rider")) // Support for CLion Nova.
intellijPlatform {
clion(ideaVersion)

Binary file not shown.

View File

@@ -1,7 +1,9 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-9.5.1-bin.zip
networkTimeout=10000
retries=0
retryBackOffMs=500
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists

15
gradlew vendored
View File

@@ -1,7 +1,7 @@
#!/bin/sh
#
# Copyright © 2015-2021 the original authors.
# Copyright © 2015 the original authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -15,6 +15,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
# SPDX-License-Identifier: Apache-2.0
#
##############################################################################
#
@@ -55,7 +57,7 @@
# Darwin, MinGW, and NonStop.
#
# (3) This script is generated from the Groovy template
# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
# https://github.com/gradle/gradle/blob/3d91ce3b8caaf77ad09f381f43615b715b53f72c/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
# within the Gradle project.
#
# You can find Gradle at https://github.com/gradle/gradle/.
@@ -84,7 +86,7 @@ done
# shellcheck disable=SC2034
APP_BASE_NAME=${0##*/}
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit
APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s\n' "$PWD" ) || exit
# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD=maximum
@@ -112,7 +114,6 @@ case "$( uname )" in #(
NONSTOP* ) nonstop=true ;;
esac
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
# Determine the Java command to use to start the JVM.
@@ -170,7 +171,6 @@ fi
# For Cygwin or MSYS, switch paths to Windows format before running java
if "$cygwin" || "$msys" ; then
APP_HOME=$( cygpath --path --mixed "$APP_HOME" )
CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" )
JAVACMD=$( cygpath --unix "$JAVACMD" )
@@ -203,15 +203,14 @@ fi
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
# Collect all arguments for the java command:
# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
# * DEFAULT_JVM_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
# and any embedded shellness will be escaped.
# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be
# treated as '${Hostname}' itself on the command line.
set -- \
"-Dorg.gradle.appname=$APP_BASE_NAME" \
-classpath "$CLASSPATH" \
org.gradle.wrapper.GradleWrapperMain \
-jar "$APP_HOME/gradle/wrapper/gradle-wrapper.jar" \
"$@"
# Stop when "xargs" is not available.

54
gradlew.bat vendored
View File

@@ -13,6 +13,8 @@
@rem See the License for the specific language governing permissions and
@rem limitations under the License.
@rem
@rem SPDX-License-Identifier: Apache-2.0
@rem
@if "%DEBUG%"=="" @echo off
@rem ##########################################################################
@@ -21,8 +23,8 @@
@rem
@rem ##########################################################################
@rem Set local scope for the variables with windows NT shell
if "%OS%"=="Windows_NT" setlocal
@rem Set local scope for the variables, and ensure extensions are enabled
setlocal EnableExtensions
set DIRNAME=%~dp0
if "%DIRNAME%"=="" set DIRNAME=.
@@ -43,13 +45,13 @@ set JAVA_EXE=java.exe
%JAVA_EXE% -version >NUL 2>&1
if %ERRORLEVEL% equ 0 goto execute
echo.
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
echo. 1>&2
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2
echo. 1>&2
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
echo location of your Java installation. 1>&2
goto fail
"%COMSPEC%" /c exit 1
:findJavaFromJavaHome
set JAVA_HOME=%JAVA_HOME:"=%
@@ -57,36 +59,24 @@ set JAVA_EXE=%JAVA_HOME%/bin/java.exe
if exist "%JAVA_EXE%" goto execute
echo.
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
echo. 1>&2
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2
echo. 1>&2
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
echo location of your Java installation. 1>&2
goto fail
"%COMSPEC%" /c exit 1
:execute
@rem Setup the command line
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
@rem Execute Gradle
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*
@rem endlocal doesn't take effect until after the line is parsed and variables are expanded
@rem which allows us to clear the local environment before executing the java command
endlocal & "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -jar "%APP_HOME%\gradle\wrapper\gradle-wrapper.jar" %* & call :exitWithErrorLevel
:end
@rem End local scope for the variables with windows NT shell
if %ERRORLEVEL% equ 0 goto mainEnd
:fail
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
rem the _cmd.exe /c_ return code!
set EXIT_CODE=%ERRORLEVEL%
if %EXIT_CODE% equ 0 set EXIT_CODE=1
if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE%
exit /b %EXIT_CODE%
:mainEnd
if "%OS%"=="Windows_NT" endlocal
:omega
:exitWithErrorLevel
@rem Use "%COMSPEC%" /c exit to allow operators to work properly in scripts
"%COMSPEC%" /c exit %ERRORLEVEL%

View File

@@ -3,7 +3,7 @@ rootProject.name = "ColoredBrackets"
pluginManagement {
plugins {
kotlin("jvm") version "2.2.20"
id("org.jetbrains.intellij.platform") version "2.11.0"
id("org.jetbrains.intellij.platform") version "2.16.0"
}
}