mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-04-19 04:51:24 +07:00
provide information message, if clean build is not possible (IDEA-359660)
(cherry picked from commit f54627a0904b2594ceb6a2919ec93278cb1ec2c0) IJ-CR-147297 GitOrigin-RevId: fb86c75a7ef6ffd6db6c7d01c0236486355d9332
This commit is contained in:
committed by
intellij-monorepo-bot
parent
254a40b321
commit
de3bc0f5d4
@@ -444,7 +444,8 @@ public final class CompileDriver {
|
||||
if (isRebuild) {
|
||||
// if possible, ensure the rebuild starts from the clean state
|
||||
// if CLEAR_OUTPUT_DIRECTORY is allowed, we can clear cached directory completely, otherwise the build won't be able to clean outputs correctly without build caches
|
||||
boolean canCleanBuildSystemData = Boolean.TRUE.equals(REBUILD_CLEAN.get(scope)) && CompilerWorkspaceConfiguration.getInstance(myProject).CLEAR_OUTPUT_DIRECTORY;
|
||||
boolean cleanBuildRequested = Boolean.TRUE.equals(REBUILD_CLEAN.get(scope));
|
||||
boolean canCleanBuildSystemData = cleanBuildRequested && CompilerWorkspaceConfiguration.getInstance(myProject).CLEAR_OUTPUT_DIRECTORY;
|
||||
|
||||
CompilerUtil.runInContext(compileContext, JavaCompilerBundle.message("progress.text.clearing.build.system.data"), (ThrowableRunnable<Throwable>)() -> {
|
||||
TaskFuture<Boolean> cancelPreload = canCleanBuildSystemData? buildManager.cancelPreloadedBuilds(myProject) : new TaskFutureAdapter<>(CompletableFuture.completedFuture(Boolean.TRUE));
|
||||
@@ -458,6 +459,13 @@ public final class CompileDriver {
|
||||
buildSystemDataCleanupTask.set(new TaskFutureAdapter<>(FileUtil.asyncDelete(Arrays.asList(systemFiles))));
|
||||
}
|
||||
}
|
||||
else {
|
||||
if (cleanBuildRequested) {
|
||||
compileContext.addMessage(
|
||||
CompilerMessageCategory.INFORMATION, JavaCompilerBundle.message("error.clean.state.rebuild.not.possible"), null, -1, -1
|
||||
);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -359,4 +359,5 @@ notification.action.install.space.plugin=Install Space plugin
|
||||
notification.action.enable.space.plugin=Enable Space plugin
|
||||
notification.title.git.crlf.config=Wrong Git line-endings configuration
|
||||
notification.content.git.crlf.config=To have working compiler caches you need to execute <code>{0}</code> command and force checkout the project
|
||||
class.can.be.record.suppress.conversion.if.annotated.description=Specify class names or package wildcards like <code>com.example.*</code>
|
||||
class.can.be.record.suppress.conversion.if.annotated.description=Specify class names or package wildcards like <code>com.example.*</code>
|
||||
error.clean.state.rebuild.not.possible=Complete cleaning of build system data is not possible, if option 'Clear output directory on rebuild' is set to 'false'. Build system data will be cleared as a part of project rebuild.
|
||||
Reference in New Issue
Block a user