Skip to content

Commit

Permalink
Fix error on case-senstive FSs due to change in plugin directory name…
Browse files Browse the repository at this point in the history
… with new build plugin (#650).
  • Loading branch information
jshiell committed Aug 26, 2024
1 parent 8ca0a4f commit 8a8b35e
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@

# CheckStyle-IDEA Changelog

* **5.94.1** Fixed: Error on case-sensitive FSs due to change in plugin directory name with new build plugin (#650).
* **5.94.0** New: Added CheckStyle 10.18.0.
* **5.93.5** Fixed: Improve fallback when the serialised Checkstyle version to use is absent (#648).
* **5.93.4** Fixed: resolved case-sensitivity problem that was breaking builds on case-sensitive FSs (in particular, CI) (#646).
Expand Down
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ plugins {
id("org.infernus.idea.checkstyle.build")
}

version = "5.94.0"
version = "5.94.1"

repositories {
mavenCentral()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ private String guessBuildPathFromClasspath() {
@Nullable
private String getPluginPath() {
try {
File pluginDir = new File(PathManager.getPluginsPath(), CheckStylePlugin.ID_PLUGIN);
File pluginDir = new File(PathManager.getPluginsPath(), pluginDirectory());
if (pluginDir.exists()) {
return pluginDir.getAbsolutePath();
}
Expand All @@ -273,10 +273,15 @@ private String getPluginPath() {
return null;
}

@NotNull
private static String pluginDirectory() {
return CheckStylePlugin.ID_PLUGIN.toLowerCase();
}

@Nullable
private String getPreinstalledPluginPath() {
try {
File preInstalledPluginDir = new File(PathManager.getPreInstalledPluginsPath(), CheckStylePlugin.ID_PLUGIN);
File preInstalledPluginDir = new File(PathManager.getPreInstalledPluginsPath(), pluginDirectory());
if (preInstalledPluginDir.exists()) {
return preInstalledPluginDir.getAbsolutePath();
}
Expand Down
1 change: 1 addition & 0 deletions src/main/resources/META-INF/plugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
<change-notes>
<![CDATA[
<ul>
<li>5.94.1: Fixed: Error on case-sensitive FSs due to change in plugin directory name with new build plugin (#650).</li>
<li>5.94.0: New: Added Checkstyle 10.18.0.</li>
<li>5.93.5: Fixed: Improve fallback when the serialised Checkstyle version to use is absent (#648).</li>
<li>5.93.4: Fixed: resolved case-sensitivity problem that was breaking builds on case-sensitive FSs (in particular, CI) (#646).</li>
Expand Down

0 comments on commit 8a8b35e

Please sign in to comment.