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
2 changes: 1 addition & 1 deletion plugins/idea/settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ pluginManagement {
}
}

rootProject.name = 'idea'
rootProject.name = 'com.mobidevelop.robovm.intellij'
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ class RoboVmSdkUnpackService(private val scope: CoroutineScope) {
/// flag, specifies that SDK was extracted
private var sdkExtracted = false

private var activeJob: Deferred<Home>? = null
private fun startUnpackJob(sdkHome: Home): Deferred<Home> = scope.async(Dispatchers.IO) {
private var activeJob: Deferred<Boolean>? = null
private fun startUnpackJob(sdkHome: Home): Deferred<Boolean> = scope.async(Dispatchers.IO) {
// using parent here as:
// - sdkHome.homeDir points to final destination (e.g. .robovm-sdks/robovm-2.3.23)
// - but `robovm-dist` contains `robovm-2.3.23` directory inside
Expand All @@ -64,7 +64,7 @@ class RoboVmSdkUnpackService(private val scope: CoroutineScope) {
} catch (_: IOException) {
}
}
sdkHome
filesWereUpdated
}

/**
Expand Down Expand Up @@ -102,13 +102,15 @@ class RoboVmSdkUnpackService(private val scope: CoroutineScope) {
if (started) {
withBackgroundProgress(project, "Unpacking RoboVm SDK...", cancellable = false) {
try {
val roboVmHome = job.await()
RoboVmPlugin.logInfo(
project,
"Installed RoboVM SDK %s to %s",
Version.getCompilerVersion(),
roboVmHome.homeDir.absolutePath
)
val filesWereUpdated = job.await()
if (filesWereUpdated) {
RoboVmPlugin.logInfo(
project,
"Installed RoboVM SDK %s to %s",
Version.getCompilerVersion(),
sdkHome.homeDir.absolutePath
)
}
} catch (e: Exception) {
RoboVmPlugin.logError(project, e.message)
throw e
Expand Down
Loading