Skip to content
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
10 changes: 5 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
scala: [2.13.14]
scala: [2.13.16]
java: [temurin@17]
runs-on: ${{ matrix.os }}
steps:
Expand Down Expand Up @@ -64,7 +64,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
scala: [2.13.14]
scala: [2.13.16]
java: [temurin@17]
runs-on: ${{ matrix.os }}
steps:
Expand All @@ -84,12 +84,12 @@ jobs:
- name: Setup sbt
uses: sbt/setup-sbt@v1

- name: Download target directories (2.13.14)
- name: Download target directories (2.13.16)
uses: actions/download-artifact@v4
with:
name: target-${{ matrix.os }}-2.13.14-${{ matrix.java }}
name: target-${{ matrix.os }}-2.13.16-${{ matrix.java }}

- name: Inflate target directories (2.13.14)
- name: Inflate target directories (2.13.16)
run: |
tar xf targets.tar
rm targets.tar
Expand Down
12 changes: 7 additions & 5 deletions build.sbt
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
import org.jetbrains.sbtidea.Keys._

ThisBuild / scalaVersion := "2.13.14"
ThisBuild / scalaVersion := "2.13.16"
ThisBuild / intellijPluginName := "intellij-hocon"
ThisBuild / intellijBuild := "242.20224.300"
ThisBuild / intellijBuild := "251.17181.31"
ThisBuild / githubWorkflowJavaVersions := Seq(JavaSpec.temurin("17"))

val junitInterfaceVersion = "0.11"
val commonsTextVersion = "1.12.0"
val junitVersion = "4.13.2"
val commonsTextVersion = "1.13.0"
val opentest4jVersion = "1.3.0"

lazy val hocon = project.in(file(".")).enablePlugins(SbtIdeaPlugin).settings(
version := "2024.2.99-SNAPSHOT",
version := "2025.1.99-SNAPSHOT",
Compile / scalaSource := baseDirectory.value / "src",
Test / scalaSource := baseDirectory.value / "test",
Compile / resourceDirectory := baseDirectory.value / "resources",
Expand All @@ -22,10 +23,11 @@ lazy val hocon = project.in(file(".")).enablePlugins(SbtIdeaPlugin).settings(
"-Xfatal-warnings",
),
ideBasePackages := Seq("org.jetbrains.plugins.hocon"),
intellijPlugins := Seq("com.intellij.properties", "com.intellij.java", "com.intellij.java-i18n").map(_.toPlugin),
intellijPlugins := Seq("com.intellij.java", "com.intellij.java-i18n", "com.intellij.modules.json").map(_.toPlugin),
libraryDependencies ++= Seq(
"org.apache.commons" % "commons-text" % commonsTextVersion,
"com.novocode" % "junit-interface" % junitInterfaceVersion % Test,
"junit" % "junit" % junitVersion % Test,
"org.opentest4j" % "opentest4j" % opentest4jVersion % Test,
),
packageLibraryMappings := Seq.empty, // allow scala-library
Expand Down
2 changes: 1 addition & 1 deletion project/build.properties
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
# suppress inspection "UnusedProperty" for whole file
sbt.version=1.10.1
sbt.version=1.10.7
4 changes: 2 additions & 2 deletions project/plugins.sbt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
addSbtPlugin("org.jetbrains" % "sbt-idea-plugin" % "3.26.2")
addSbtPlugin("org.jetbrains.scala" % "sbt-ide-settings" % "1.1.1")
addSbtPlugin("org.jetbrains" % "sbt-idea-plugin" % "4.0.3")
addSbtPlugin("org.jetbrains.scala" % "sbt-ide-settings" % "1.1.2")
addSbtPlugin("com.github.sbt" % "sbt-github-actions" % "0.24.0")
5 changes: 3 additions & 2 deletions resources/META-INF/plugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,12 @@
<id>org.jetbrains.plugins.hocon</id>
<name>HOCON</name>
<description>Standalone HOCON plugin for IntelliJ IDEA</description>
<version>2024.2.99-SNAPSHOT</version>
<version>2025.1.99-SNAPSHOT</version>
<vendor>Roman Janusz, AVSystem, JetBrains</vendor>
<idea-version since-build="242.0" until-build="250.0"/>
<idea-version since-build="251.0" until-build="260.0"/>
<depends>com.intellij.modules.platform</depends>
<depends>com.intellij.modules.lang</depends>
<depends>com.intellij.modules.json</depends>
<depends optional="true" config-file="hocon-java.xml">com.intellij.modules.java</depends>

<change-notes>
Expand Down
8 changes: 4 additions & 4 deletions test/org/jetbrains/plugins/hocon/HoconActionTest.scala
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,10 @@ object HoconActionTest {

private def mockDataContext(file: PsiFile, editor: Editor) = {
val parentContext = DataManager.getInstance().getDataContext(editor.getComponent)
CustomizedDataContext.withProvider(parentContext, (dataId: String) => {
if (CommonDataKeys.PROJECT is dataId) file.getProject
else if (CommonDataKeys.EDITOR is dataId) editor
else null
CustomizedDataContext.withSnapshot(parentContext, (sink: DataSink) => {
sink.set(CommonDataKeys.PROJECT, file.getProject)
sink.set(CommonDataKeys.EDITOR, editor)
sink.set(CommonDataKeys.PSI_FILE, file)
})
}

Expand Down
Loading