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
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@ repos:
hooks:
- id: prettier
additional_dependencies:
- prettier@3.3.3
- "@prettier/plugin-xml@3.4.1"
- prettier@3.6.2
- "@prettier/plugin-xml@3.4.2"
21 changes: 10 additions & 11 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -30,16 +30,15 @@ repositories {
}

dependencies {
testImplementation("com.squareup.okhttp3:okhttp:4.12.0") // needed for connecting to remote robot
testImplementation(libs.jupiter)
testRuntimeOnly(libs.jupiterEngine)
testRuntimeOnly("junit:junit:4.13.2") // https://github.com/JetBrains/intellij-platform-gradle-plugin/issues/1711
testRuntimeOnly(libs.junitPlatformLauncher)
testRuntimeOnly("junit:junit:4.13.2") // legacy JUnit 4 support
testImplementation(libs.remoteRobot)
testImplementation(libs.remoteRobotFixtures)
intellijPlatform {
pycharmCommunity(platformVersion)
bundledPlugin("PythonCore")
instrumentationTools()
pluginVerifier()
zipSigner()
testFramework(TestFrameworkType.JUnit5)
Expand Down Expand Up @@ -101,13 +100,13 @@ intellijPlatform {
pluginVerification {
ides {
// target supporting the following platforms
ide(IntelliJPlatformType.PyCharmCommunity, platformVersion)
ide(IntelliJPlatformType.PyCharmProfessional, platformVersion)
ide(IntelliJPlatformType.IntellijIdeaCommunity, platformVersion)
ide(IntelliJPlatformType.IntellijIdeaUltimate, platformVersion)
ide(IntelliJPlatformType.GoLand, platformVersion)
ide(IntelliJPlatformType.CLion, platformVersion)
ide(IntelliJPlatformType.RustRover, platformVersion)
create(IntelliJPlatformType.PyCharmCommunity, platformVersion)
create(IntelliJPlatformType.PyCharmProfessional, platformVersion)
create(IntelliJPlatformType.IntellijIdeaCommunity, platformVersion)
create(IntelliJPlatformType.IntellijIdeaUltimate, platformVersion)
create(IntelliJPlatformType.GoLand, platformVersion)
create(IntelliJPlatformType.CLion, platformVersion)
create(IntelliJPlatformType.RustRover, platformVersion)
}
}
}
Expand Down Expand Up @@ -164,6 +163,6 @@ val runIdeForUiTests by intellijPlatformTesting.runIde.registering {

versionCatalogUpdate {
keep {
keepUnusedPlugins.set(true) // taskinfo is unused but that is fine
keepUnusedVersions = true
}
}
16 changes: 9 additions & 7 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,21 +1,23 @@
[versions]
changelog = "2.2.1"
intelliJPlatform = "2.0.1"
jupiter = "5.10.3"
kotlin = "2.0.10"
changelog = "2.4.0"
intelliJPlatform = "2.10.0"
junitPlatformLauncher= "1.14.0"
jupiter = "5.14.0"
kotlin = "2.2.20"
kover = "0.9.2"
ktlint = "12.1.1"
ktlint = "13.1.0"
remoteRobot = "0.11.23"
taskinfo = "2.2.0"
testLogger = "4.0.0"
versionPlugin = "0.51.0"
versionUpdate = "0.8.4"
versionPlugin = "0.53.0"
versionUpdate = "1.0.1"

[libraries]
jupiter = { module = "org.junit.jupiter:junit-jupiter-api", version.ref = "jupiter" }
jupiterEngine = { module = "org.junit.jupiter:junit-jupiter-engine", version.ref = "jupiter" }
remoteRobot = { module = "com.intellij.remoterobot:remote-robot", version.ref = "remoteRobot" }
remoteRobotFixtures = { module = "com.intellij.remoterobot:remote-fixtures", version.ref = "remoteRobot" }
junitPlatformLauncher = { module = "org.junit.platform:junit-platform-launcher", version.ref = "junitPlatformLauncher" }

[plugins]
changelog = { id = "org.jetbrains.changelog", version.ref = "changelog" }
Expand Down
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.9-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-9.1.0-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,18 +27,23 @@ abstract class ConfigurePythonActionAbstract : AnAction() {
// - any files within the binary folder.
e.presentation.isEnabledAndVisible =
when (val selectedPath = e.getData(CommonDataKeys.VIRTUAL_FILE)) {
null -> false
else ->
null -> {
false
}

else -> {
when (selectedPath.isDirectory) {
true -> {
// check if there is a python executable available under this folder -> name match for binary
PythonSdkUtil.getPythonExecutable(selectedPath.path) != null
}

false -> {
// check for presence of the activate_this.py + activate alongside or pyvenv.cfg above
PythonSdkUtil.isVirtualEnv(selectedPath.path)
}
}
}
}
}

Expand Down