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

Add 2023.1 and 2023.2 compatibility. Minimal required version is now 2022.3 #6

Merged
merged 2 commits into from
Aug 22, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 2 additions & 7 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# GitHub Actions Workflow created for testing and preparing the plugin release in following steps:
# - validate Gradle Wrapper,
# - run 'test' and 'verifyPlugin' tasks,
# - run Qodana inspections,
# - run 'buildPlugin' task and prepare artifact for the further tests,
# - run 'runPluginVerifier' task,
# - create a draft release.
Expand Down Expand Up @@ -48,12 +47,12 @@ jobs:
- name: Gradle Wrapper Validation
uses: gradle/wrapper-validation-action@v1.0.4

# Setup Java 11 environment for the next steps
# Setup Java 17 environment for the next steps
- name: Setup Java
uses: actions/setup-java@v3
with:
distribution: zulu
java-version: 11
java-version: 17

# Set environment variables
- name: Export Properties
Expand Down Expand Up @@ -106,10 +105,6 @@ jobs:
name: pluginVerifier-result
path: ${{ github.workspace }}/build/reports/pluginVerifier

# Run Qodana inspections
- name: Qodana - Code Inspection
uses: JetBrains/qodana-action@v2022.2.1

# Prepare plugin archive content for creating artifact
- name: Prepare Plugin Artifact
id: artifact
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,12 @@ jobs:
with:
ref: ${{ github.event.release.tag_name }}

# Setup Java 11 environment for the next steps
# Setup Java 17 environment for the next steps
- name: Setup Java
uses: actions/setup-java@v3
with:
distribution: zulu
java-version: 11
java-version: 17

# Set environment variables
- name: Export Properties
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/run-ui-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,12 @@ jobs:
- name: Fetch Sources
uses: actions/checkout@v3

# Setup Java 11 environment for the next steps
# Setup Java 17 environment for the next steps
- name: Setup Java
uses: actions/setup-java@v3
with:
distribution: zulu
java-version: 11
java-version: 17

# Run IDEA prepared for UI testing
- name: Run IDE
Expand Down
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
.gradle
.idea
.qodana
build
26 changes: 0 additions & 26 deletions .run/Run Qodana.run.xml

This file was deleted.

5 changes: 4 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
# intellij-kdl Changelog

## [Unreleased]
### Added
- 2023.1 and 2023.2 compatibility
- Minimal required version is now 2022.3

## [1.0.1]
### Added
### Added
- 2022.3 compatibility

## [1.0.0]
Expand Down
18 changes: 5 additions & 13 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ plugins {
id("org.jetbrains.kotlin.jvm") version "1.7.10"
id("org.jetbrains.intellij") version "1.9.0"
id("org.jetbrains.changelog") version "1.3.1"
id("org.jetbrains.qodana") version "0.1.13"
id("org.jetbrains.grammarkit") version "2021.2.2"
id("org.jetbrains.grammarkit") version "2022.3.1"
id("org.ajoberstar.grgit") version "5.0.0"
}

Expand All @@ -25,7 +24,7 @@ repositories {

kotlin {
jvmToolchain {
languageVersion.set(JavaLanguageVersion.of(11))
languageVersion.set(JavaLanguageVersion.of(17))
}
}

Expand All @@ -42,13 +41,6 @@ changelog {
groups.set(emptyList())
}

qodana {
cachePath.set(projectDir.resolve(".qodana").canonicalPath)
reportPath.set(projectDir.resolve("build/reports/inspections").canonicalPath)
saveReport.set(true)
showReport.set(System.getenv("QODANA_SHOW_REPORT")?.toBoolean() ?: false)
}

tasks {
wrapper {
gradleVersion = properties("gradleVersion")
Expand Down Expand Up @@ -114,21 +106,21 @@ sourceSets {
}

val generateKdlLexer = task<GenerateLexerTask>("generateKdlLexer") {
source.set("src/main/grammars/KdlLexer.flex")
sourceFile.set(file("src/main/grammars/KdlLexer.flex"))
targetDir.set("src/genparser/dev/kdl/lang/lexer")
targetClass.set("KdlLexer")
purgeOldFiles.set(true)
}

val generateKdlStringLexer = task<GenerateLexerTask>("generateKdlStringLexer") {
source.set("src/main/grammars/KdlStringLexer.flex")
sourceFile.set(file("src/main/grammars/KdlStringLexer.flex"))
targetDir.set("src/genparser/dev/kdl/lang/escape")
targetClass.set("KdlStringLexer")
purgeOldFiles.set(true)
}

val generateKdlParser = task<GenerateParserTask>("generateKdlParser") {
source.set("src/main/grammars/KdlParser.bnf")
sourceFile.set(file("src/main/grammars/KdlParser.bnf"))
targetRoot.set("src/genparser")
pathToParser.set("dev/kdl/lang/parser/KdlParser.java")
pathToPsiRoot.set("dev/kdl/lang/psi")
Expand Down
10 changes: 5 additions & 5 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
pluginGroup=dev.kdl
pluginName=intellij-kdl
pluginVersion=1.0.1
pluginVersion=2.0.0

pluginSinceBuild=213
pluginUntilBuild=223.*
pluginSinceBuild=223
pluginUntilBuild=232.*

platformType=IC
platformVersion=2021.3.3
platformVersion=2022.3

platformPlugins=PsiViewer:213-SNAPSHOT
platformPlugins=PsiViewer:2022.3

gradleVersion=7.5.1

Expand Down
7 changes: 0 additions & 7 deletions qodana.yml

This file was deleted.

2 changes: 1 addition & 1 deletion src/main/kotlin/dev/kdl/lang/formatter/KdlBlock.kt
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import dev.kdl.lang.children
import dev.kdl.lang.parser.KdlParserDefinition.Companion.WHITESPACES
import dev.kdl.lang.psi.ext.KdlElementTypes.*

class KdlBlock constructor(
class KdlBlock(
node: ASTNode,
wrap: Wrap?,
private val indent: Indent,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package dev.kdl.lang.highlighter;
package dev.kdl.lang.highlighter

import com.intellij.lexer.LayeredLexer
import com.intellij.psi.tree.IElementType
Expand Down
2 changes: 1 addition & 1 deletion src/main/kotlin/dev/kdl/lang/psi/KdlElementFactory.kt
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ object KdlElementFactory {
.string!!
}

fun createFile(project: Project, text: String): KdlPsiFile {
private fun createFile(project: Project, text: String): KdlPsiFile {
return PsiFileFactory.getInstance(project)
.createFileFromText("dummy.kdl", KdlFileType, text) as KdlPsiFile
}
Expand Down
Loading