[python] PY-79486: (WIP) split pyproject.toml tools into backend/common.

Each tool (uv, poetry) now has `common` and `backend` part. `common` has icons because we need them both on the front and on the back.

We might need to create `front` module also if we wouldn't be able to use icons in compose.

GitOrigin-RevId: b5662fbdf3d23f1ddaa5926469d1cfd2051a0fba
This commit is contained in:
Ilya.Kazakevich
2025-10-16 17:21:59 +00:00
committed by intellij-monorepo-bot
parent 29badacb2b
commit c183e6e634
98 changed files with 395 additions and 166 deletions
+1
View File
@@ -37,6 +37,7 @@ jvm_library(
"//libraries/kotlinx/serialization/core",
"@lib//:io-github-z4kn4fein-semver-jvm-provided",
"//python/python-sdk-ui:sdk-ui",
"//python/common",
]
)
### auto-generated section `build intellij.python.hatch` end
@@ -46,5 +46,6 @@
<orderEntry type="module" module-name="intellij.libraries.kotlinx.serialization.core" />
<orderEntry type="library" scope="PROVIDED" name="io.github.z4kn4fein.semver.jvm" level="project" />
<orderEntry type="module" module-name="intellij.python.sdk.ui" />
<orderEntry type="module" module-name="intellij.python.common" />
</component>
</module>
@@ -5,6 +5,7 @@
<module name="intellij.python.sdk"/>
<module name="intellij.python.sdk.ui"/>
<module name="intellij.python.pyproject"/>
<module name="intellij.python.common"/>
</dependencies>
<extensions defaultExtensionNs="Pythonid">
@@ -15,4 +16,7 @@
<extensions defaultExtensionNs="com.intellij.python.pyproject.model">
<tool implementation="com.intellij.python.hatch.impl.HatchTool"/>
</extensions>
<extensions defaultExtensionNs="com.intellij">
<python.common.toolToIconMapper implementation="com.intellij.python.hatch.impl.HatchIdMapper"/>
</extensions>
</idea-plugin>
@@ -0,0 +1,11 @@
package com.intellij.python.hatch.impl
import com.intellij.python.common.tools.ToolId
import com.intellij.python.common.tools.spi.ToolIdToIconMapper
import com.intellij.python.hatch.icons.PythonHatchIcons
import javax.swing.Icon
internal class HatchIdMapper : ToolIdToIconMapper {
override val id: ToolId = HATCH_TOOL_ID
override val icon: Icon = PythonHatchIcons.Logo
}
@@ -2,13 +2,13 @@
package com.intellij.python.hatch.impl
import com.intellij.openapi.util.NlsSafe
import com.intellij.python.common.tools.ToolId
import com.intellij.python.hatch.icons.PythonHatchIcons
import com.intellij.python.pyproject.model.spi.ProjectName
import com.intellij.python.pyproject.model.spi.ProjectStructureInfo
import com.intellij.python.pyproject.model.spi.PyProjectTomlProject
import com.intellij.python.pyproject.model.spi.Tool
import com.jetbrains.python.PyToolUIInfo
import com.jetbrains.python.ToolId
import com.jetbrains.python.venvReader.Directory
import org.apache.tuweni.toml.TomlTable
import org.jetbrains.annotations.ApiStatus