mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Remove dependency intellij.platform.execution.impl -> intellij.platform, IDEA-CR-1366
GitOrigin-RevId: dd384083cfff65a671d89de5cd5058073ddf9478
This commit is contained in:
committed by
intellij-monorepo-bot
parent
1ce99aab3b
commit
69b8d50265
@@ -14,7 +14,6 @@
|
||||
<orderEntry type="module" module-name="intellij.platform.ide.impl" />
|
||||
<orderEntry type="library" name="miglayout-swing" level="project" />
|
||||
<orderEntry type="library" name="Guava" level="project" />
|
||||
<orderEntry type="module" module-name="intellij.platform.vcs" />
|
||||
<orderEntry type="library" name="StreamEx" level="project" />
|
||||
</component>
|
||||
</module>
|
||||
+6
-6
@@ -32,8 +32,6 @@ import com.intellij.openapi.ui.popup.LightweightWindowEvent;
|
||||
import com.intellij.openapi.util.Disposer;
|
||||
import com.intellij.openapi.util.IconLoader;
|
||||
import com.intellij.openapi.util.text.StringUtil;
|
||||
import com.intellij.openapi.vcs.ProjectLevelVcsManager;
|
||||
import com.intellij.openapi.vcs.changes.VcsIgnoreManager;
|
||||
import com.intellij.openapi.vfs.LocalFileSystem;
|
||||
import com.intellij.openapi.vfs.VirtualFile;
|
||||
import com.intellij.project.ProjectKt;
|
||||
@@ -486,15 +484,17 @@ public final class SingleConfigurationConfigurable<Config extends RunConfigurati
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
// 3. If the project is not under VCS, keep using .idea/runConfigurations
|
||||
if (!ProjectLevelVcsManager.getInstance(myProject).hasActiveVcss()) {
|
||||
RunConfigurationVcsSupport vcsSupport = myProject.getService(RunConfigurationVcsSupport.class);
|
||||
if (!vcsSupport.hasActiveVcss(myProject)) {
|
||||
myRCStorageType = RCStorageType.DotIdeaFolder;
|
||||
myFolderPathIfStoredInArbitraryFile = null;
|
||||
return;
|
||||
}
|
||||
|
||||
// 4. If .idea/runConfigurations is not excluded from VCS (e.g. not in .gitignore), then use it
|
||||
if (!isDotIdeaStorageVcsIgnored()) {
|
||||
if (!isDotIdeaStorageVcsIgnored(vcsSupport)) {
|
||||
myRCStorageType = RCStorageType.DotIdeaFolder;
|
||||
myFolderPathIfStoredInArbitraryFile = null;
|
||||
return;
|
||||
@@ -524,9 +524,9 @@ public final class SingleConfigurationConfigurable<Config extends RunConfigurati
|
||||
myFolderPathIfStoredInArbitraryFile = baseDir.getPath() + "/.run";
|
||||
}
|
||||
|
||||
private boolean isDotIdeaStorageVcsIgnored() {
|
||||
private boolean isDotIdeaStorageVcsIgnored(RunConfigurationVcsSupport vcsSupport) {
|
||||
if (myDotIdeaStorageVcsIgnored == null) {
|
||||
myDotIdeaStorageVcsIgnored = VcsIgnoreManager.getInstance(myProject).isDirectoryVcsIgnored(getDotIdeaStoragePath(myProject));
|
||||
myDotIdeaStorageVcsIgnored = vcsSupport.isDirectoryVcsIgnored(myProject, getDotIdeaStoragePath(myProject));
|
||||
}
|
||||
return myDotIdeaStorageVcsIgnored.booleanValue();
|
||||
}
|
||||
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
|
||||
package com.intellij.execution.configurations
|
||||
|
||||
import com.intellij.openapi.project.Project
|
||||
import org.jetbrains.annotations.ApiStatus
|
||||
|
||||
@ApiStatus.Internal
|
||||
open class RunConfigurationVcsSupport {
|
||||
open fun hasActiveVcss(project: Project) = false
|
||||
open fun isDirectoryVcsIgnored(project: Project, path: String) = false
|
||||
}
|
||||
@@ -681,6 +681,8 @@
|
||||
<projectConfigurable groupId="build" id="Runtime.Targets.Configurable" bundle="messages.IdeBundle" key="configurable.Runtime.Targets.Configurable.display.name"
|
||||
provider="com.intellij.execution.target.TargetEnvironmentsConfigurableProvider"/>
|
||||
|
||||
<projectService serviceImplementation="com.intellij.execution.configurations.RunConfigurationVcsSupport" />
|
||||
|
||||
<findUsagesHandlerFactory implementation="com.intellij.find.findUsages.DefaultFindUsagesHandlerFactory" id="default" order="last"/>
|
||||
<usageTargetProvider implementation="com.intellij.find.findUsages.DefaultUsageTargetProvider" id="default" order="last"/>
|
||||
|
||||
|
||||
@@ -222,6 +222,9 @@
|
||||
<notificationWhitelist groupIds="Vcs Important Messages;Vcs Notifications;Vcs Silent Notifications;Vcs Messages;
|
||||
Common Version Control Messages" notificationIds="ignored.to.exclude.synchronization.notification;externally.added.files.notification;
|
||||
project.configuration.files.added.notification;manage.ignore.files.notification"/>
|
||||
<projectService serviceInterface="com.intellij.execution.configurations.RunConfigurationVcsSupport"
|
||||
serviceImplementation="com.intellij.impl.RunConfigurationVcsSupportImpl"
|
||||
overrides="true"/>
|
||||
</extensions>
|
||||
|
||||
<applicationListeners>
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
|
||||
package com.intellij.impl
|
||||
|
||||
import com.intellij.execution.configurations.RunConfigurationVcsSupport
|
||||
import com.intellij.openapi.project.Project
|
||||
import com.intellij.openapi.vcs.ProjectLevelVcsManager
|
||||
import com.intellij.openapi.vcs.changes.VcsIgnoreManager
|
||||
|
||||
class RunConfigurationVcsSupportImpl : RunConfigurationVcsSupport() {
|
||||
override fun hasActiveVcss(project: Project): Boolean {
|
||||
return ProjectLevelVcsManager.getInstance(project).hasActiveVcss()
|
||||
}
|
||||
override fun isDirectoryVcsIgnored(project: Project, path: String): Boolean {
|
||||
return VcsIgnoreManager.getInstance(project).isDirectoryVcsIgnored(path)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user