Compare commits
No commits in common. "2a406feb15782c0079c56b157a9e67fac1d06284" and "852e24bc18f08f4079a7b51a1981d2bff963dc98" have entirely different histories.
2a406feb15
...
852e24bc18
2 changed files with 17 additions and 23 deletions
|
@ -3,8 +3,8 @@ bld.downloadExtensionSources=true
|
||||||
bld.downloadLocation=
|
bld.downloadLocation=
|
||||||
bld.javaOptions=
|
bld.javaOptions=
|
||||||
bld.javacOptions=
|
bld.javacOptions=
|
||||||
bld.extension-exec=com.uwyn.rife2:bld-exec:1.0.5
|
bld.extension-exec=com.uwyn.rife2:bld-exec:1.0.4
|
||||||
bld.extension-pmd=com.uwyn.rife2:bld-pmd:1.2.2
|
bld.extension-pmd=com.uwyn.rife2:bld-pmd:1.2.1
|
||||||
bld.repositories=MAVEN_CENTRAL,MAVEN_LOCAL,RIFE2_SNAPSHOTS,RIFE2_RELEASES
|
bld.repositories=MAVEN_CENTRAL,MAVEN_LOCAL,RIFE2_SNAPSHOTS,RIFE2_RELEASES
|
||||||
bld.sourceDirectories=
|
bld.sourceDirectories=
|
||||||
bld.version=2.2.1
|
bld.version=2.2.1
|
||||||
|
|
|
@ -122,21 +122,12 @@ public class CompileKotlinOperation extends AbstractOperation<CompileKotlinOpera
|
||||||
}
|
}
|
||||||
|
|
||||||
// Common installation paths (e.g., SDKMAN!, IntelliJ IDEA, etc.)
|
// Common installation paths (e.g., SDKMAN!, IntelliJ IDEA, etc.)
|
||||||
var commonPaths = new LinkedHashMap<String, String>(); //NOPMD no concurrent access
|
var commonPaths = new HashMap<String, String>(); //NOPMD no concurrent access
|
||||||
|
|
||||||
if (isLinux()) {
|
if (isLinux()) {
|
||||||
var userHome = System.getProperty("user.home");
|
var userHome = System.getProperty("user.home");
|
||||||
if (userHome != null) {
|
if (userHome != null) {
|
||||||
commonPaths.put(userHome + "/.sdkman/candidates/kotlin/current/bin", "SDKMAN!");
|
commonPaths.put(userHome + "/.sdkman/candidates/kotlin/current/bin", "SDKMAN");
|
||||||
}
|
|
||||||
commonPaths.put("/snap/bin", "Kotlin (Snap)");
|
|
||||||
commonPaths.put("/usr/bin", null);
|
|
||||||
commonPaths.put("/usr/share", null);
|
|
||||||
commonPaths.put("/usr/local/bin", null);
|
|
||||||
commonPaths.put("/usr/local/kotlin/bin", null);
|
|
||||||
commonPaths.put("/usr/share/kotlin/bin/", null);
|
|
||||||
commonPaths.put("/opt/kotlin/bin", null);
|
|
||||||
if (userHome != null) {
|
|
||||||
commonPaths.put(userHome + "/.local/share/JetBrains/Toolbox/apps/intellij-idea-ultimate/plugins/Kotlin/kotlinc/bin",
|
commonPaths.put(userHome + "/.local/share/JetBrains/Toolbox/apps/intellij-idea-ultimate/plugins/Kotlin/kotlinc/bin",
|
||||||
"IntelliJ IDEA Ultimate");
|
"IntelliJ IDEA Ultimate");
|
||||||
commonPaths.put(userHome + "/.local/share/JetBrains/Toolbox/apps/intellij-idea-community-edition/plugins/Kotlin/kotlinc/bin",
|
commonPaths.put(userHome + "/.local/share/JetBrains/Toolbox/apps/intellij-idea-community-edition/plugins/Kotlin/kotlinc/bin",
|
||||||
|
@ -144,14 +135,14 @@ public class CompileKotlinOperation extends AbstractOperation<CompileKotlinOpera
|
||||||
commonPaths.put(userHome + "/.local/share/JetBrains/Toolbox/apps/android-studio/plugins/Kotlin/kotlinc/bin",
|
commonPaths.put(userHome + "/.local/share/JetBrains/Toolbox/apps/android-studio/plugins/Kotlin/kotlinc/bin",
|
||||||
"Android Studio");
|
"Android Studio");
|
||||||
}
|
}
|
||||||
commonPaths.put("/snap/intellij-idea-ultimate/current/commons/plugins/Kotlin/kotlinc/bin",
|
commonPaths.put("/usr/bin", null);
|
||||||
"IntelliJ IDEA Ultimate (Snap)");
|
commonPaths.put("/usr/share", null);
|
||||||
commonPaths.put("/snap/intellij-idea-community/current/commons/plugins/Kotlin/kotlinc/bin",
|
commonPaths.put("/usr/local/bin", null);
|
||||||
"IntelliJ IDEA Community Edition (Snap)");
|
commonPaths.put("/usr/local/kotlin/bin", null);
|
||||||
commonPaths.put("/snap/android-studio/current/android-studio/commons/plugins/Kotlin/kotlinc/bin",
|
commonPaths.put("/usr/share/kotlin/bin/", null);
|
||||||
"Android Studio (Snap)");
|
commonPaths.put("/opt/kotlin/bin", null);
|
||||||
} else if (isWindows()) {
|
} else if (isWindows()) {
|
||||||
commonPaths.put("C:\\tools\\kotlinc\\bin", null);
|
commonPaths.put("C:\\tools\\kotlinc", null);
|
||||||
var localAppData = System.getenv("LOCALAPPDATA");
|
var localAppData = System.getenv("LOCALAPPDATA");
|
||||||
if (localAppData != null) {
|
if (localAppData != null) {
|
||||||
commonPaths.put(localAppData + "\\Programs\\IntelliJ IDEA Ultimate\\plugins\\Kotlin\\kotlinc\\bin",
|
commonPaths.put(localAppData + "\\Programs\\IntelliJ IDEA Ultimate\\plugins\\Kotlin\\kotlinc\\bin",
|
||||||
|
@ -163,21 +154,21 @@ public class CompileKotlinOperation extends AbstractOperation<CompileKotlinOpera
|
||||||
}
|
}
|
||||||
var programFiles = System.getenv("ProgramFiles");
|
var programFiles = System.getenv("ProgramFiles");
|
||||||
if (programFiles != null) {
|
if (programFiles != null) {
|
||||||
commonPaths.put(programFiles + "\\Kotlin\\bin", null);
|
commonPaths.put(programFiles + File.separator + "Kotlin", "null");
|
||||||
}
|
}
|
||||||
} else if (isMacOS()) {
|
} else if (isMacOS()) {
|
||||||
var userHome = System.getProperty("user.home");
|
var userHome = System.getProperty("user.home");
|
||||||
if (userHome != null) {
|
if (userHome != null) {
|
||||||
commonPaths.put(userHome + "/.sdkman/candidates/kotlin/current/bin", "SDKMAN!");
|
commonPaths.put(userHome + "/.sdkman/candidates/kotlin/current/bin", "SDKMAN!");
|
||||||
}
|
}
|
||||||
commonPaths.put("/opt/homebrew/bin", "Homebrew");
|
|
||||||
commonPaths.put("/usr/local/bin", null);
|
|
||||||
commonPaths.put("/Applications/IntelliJ IDEA.app/Contents/plugins/Kotlin/kotlinc/bin/",
|
commonPaths.put("/Applications/IntelliJ IDEA.app/Contents/plugins/Kotlin/kotlinc/bin/",
|
||||||
"IntelliJ IDEA");
|
"IntelliJ IDEA");
|
||||||
commonPaths.put("/Applications/IntelliJ IDEA Community Edition.app/Contents/plugins/Kotlin/kotlinc/bin/",
|
commonPaths.put("/Applications/IntelliJ IDEA Community Edition.app/Contents/plugins/Kotlin/kotlinc/bin/",
|
||||||
"IntelliJ IDEA Community Edition");
|
"IntelliJ IDEA Community Edition");
|
||||||
commonPaths.put("/Applications/Android Studio.app/Contents/plugins/Kotlin/kotlinc/bin",
|
commonPaths.put("/Applications/Android Studio.app/Contents/plugins/Kotlin/kotlinc/bin",
|
||||||
"Android Studio");
|
"Android Studio");
|
||||||
|
commonPaths.put("/usr/local/bin", null);
|
||||||
|
commonPaths.put("/opt/homebrew/bin", "Homebrew");
|
||||||
}
|
}
|
||||||
|
|
||||||
for (var path : commonPaths.keySet()) {
|
for (var path : commonPaths.keySet()) {
|
||||||
|
@ -187,6 +178,9 @@ public class CompileKotlinOperation extends AbstractOperation<CompileKotlinOpera
|
||||||
return kotlincPath;
|
return kotlincPath;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
commonPaths.forEach((path, where) -> {
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
// Try 'which' or 'where' commands (less reliable but sometimes works)
|
// Try 'which' or 'where' commands (less reliable but sometimes works)
|
||||||
try {
|
try {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue