From 47b366eb7d065eec2796bfee32ee7fe8ac80748b Mon Sep 17 00:00:00 2001 From: Kellen Dye Date: Thu, 26 Oct 2023 01:17:20 -0400 Subject: [PATCH 1/4] Use patchPluginXml --- build.sbt | 9 ++++++++- src/main/resources/META-INF/plugin.xml | 2 +- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/build.sbt b/build.sbt index 5dfe188..04fed66 100644 --- a/build.sbt +++ b/build.sbt @@ -45,11 +45,18 @@ lazy val commonSettings = Def.settings( ) ) +lazy val prePackageArtifact = taskKey[Unit]("Force doPatchPluginXml run before artifact is built") +prePackageArtifact := Def.sequential(packageMappings, doPatchPluginXml).value +packageArtifact := (packageArtifact dependsOn prePackageArtifact).value + lazy val ideaSettings = Def.settings( ThisBuild / intellijPluginName := "scio-idea", ThisBuild / intellijPlatform := IntelliJPlatform.IdeaCommunity, ThisBuild / intellijBuild := "232.10072.27", - intellijPlugins += "org.intellij.scala".toPlugin + intellijPlugins += "org.intellij.scala".toPlugin, + patchPluginXml := pluginXmlOptions { xml => + xml.version = version.value + } ) lazy val scioIdeaPlugin: Project = project diff --git a/src/main/resources/META-INF/plugin.xml b/src/main/resources/META-INF/plugin.xml index bf7816a..0515254 100644 --- a/src/main/resources/META-INF/plugin.xml +++ b/src/main/resources/META-INF/plugin.xml @@ -1,7 +1,7 @@ com.spotify.scio-idea Scio IDEA - 0.1.24 + FILLED_BY_BUILD Spotify IntelliJ IDEA plugin for Scio - https://github.com/spotify/scio From 975ed70e18e6f2dbe485b40c68996c9179199e8e Mon Sep 17 00:00:00 2001 From: Kellen Dye Date: Thu, 26 Oct 2023 02:01:37 -0400 Subject: [PATCH 2/4] simpler --- build.sbt | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/build.sbt b/build.sbt index 04fed66..6ca63ea 100644 --- a/build.sbt +++ b/build.sbt @@ -45,9 +45,8 @@ lazy val commonSettings = Def.settings( ) ) -lazy val prePackageArtifact = taskKey[Unit]("Force doPatchPluginXml run before artifact is built") -prePackageArtifact := Def.sequential(packageMappings, doPatchPluginXml).value -packageArtifact := (packageArtifact dependsOn prePackageArtifact).value +// Avoid racing doPatchPluginXml against packageMappings +packageArtifact := (packageArtifact dependsOn Def.sequential(packageMappings, doPatchPluginXml)).value lazy val ideaSettings = Def.settings( ThisBuild / intellijPluginName := "scio-idea", From a4612ba23ebdd9a964e5f1e251aaf9fc64df4f43 Mon Sep 17 00:00:00 2001 From: Kellen Dye Date: Thu, 26 Oct 2023 02:25:19 -0400 Subject: [PATCH 3/4] scalafmt --- build.sbt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/build.sbt b/build.sbt index 6ca63ea..fce116c 100644 --- a/build.sbt +++ b/build.sbt @@ -46,7 +46,9 @@ lazy val commonSettings = Def.settings( ) // Avoid racing doPatchPluginXml against packageMappings -packageArtifact := (packageArtifact dependsOn Def.sequential(packageMappings, doPatchPluginXml)).value +packageArtifact := { + packageArtifact dependsOn Def.sequential(packageMappings, doPatchPluginXml) +}.value lazy val ideaSettings = Def.settings( ThisBuild / intellijPluginName := "scio-idea", From eab8f273f791461213168afe123c3c98d7b44e56 Mon Sep 17 00:00:00 2001 From: Kellen Dye Date: Thu, 26 Oct 2023 08:44:52 -0400 Subject: [PATCH 4/4] Fix accidentally overwritten vendor, bump version --- src/main/resources/META-INF/plugin.xml | 2 +- version.sbt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/resources/META-INF/plugin.xml b/src/main/resources/META-INF/plugin.xml index 0515254..822e341 100644 --- a/src/main/resources/META-INF/plugin.xml +++ b/src/main/resources/META-INF/plugin.xml @@ -2,7 +2,7 @@ com.spotify.scio-idea Scio IDEA FILLED_BY_BUILD - Spotify + Spotify IntelliJ IDEA plugin for Scio - https://github.com/spotify/scio diff --git a/version.sbt b/version.sbt index b2da1a2..57dd134 100644 --- a/version.sbt +++ b/version.sbt @@ -1 +1 @@ -ThisBuild / version := "0.1.24" +ThisBuild / version := "0.1.25"