String (MavenProject project, String goal) { List<String> result = new ArrayList<>(); MavenCompilerTask compilerTask = new MavenCompilerTask(project.getPath(), goal); synchronized (myStateLock) { for (Phase phase : Phase.values()) { if (myState.getTasks(phase).contains(compilerTask)) { result.add(TasksBundle.message(phase.myMessageKey)); } } } for (MavenBeforeRunTask each : RunManagerEx.getInstanceEx(myProject).getBeforeRunTasks(MavenBeforeRunTasksProvider.ID)) { if (each.isFor(project, goal)) { result.add(TasksBundle.message("maven.tasks.goal.before.run")); break; } } return StringUtil.join(result, ", "); }