Standardmäßig ist der Prompt ausgewählt, der zuerst die Quelle prüft. Sie können zu einem direkten Befehl wechseln oder eine lokale Kopie herunterladen.
Quelldateien prüfen
Lesen Sie SKILL.md und alle von SkillsMP angezeigten Begleitdateien, bevor Sie sich für eine Installation entscheiden.
Mit Codex oder Claude installieren Kopieren Sie diesen Prompt, fügen Sie ihn in Codex, Claude oder einen anderen Assistant ein und lassen Sie die Skill-Seite prüfen und installieren.
Ein direkter Befehl überspringt den Prüf-Prompt. Prüfen Sie die Quelle, bevor Sie ihn ausführen.
Create or modify IntelliJ pseudo-KMP modules using expect/actual emulation.
Pseudo-KMP Modules
The monorepo is compiled by JPS, which does not support Kotlin Multiplatform. To emulate KMP expect/actual declarations, the Fleet team created the expects-compiler-plugin. This skill covers how to set up and work with modules that use this mechanism.
Register in the structure test. Add your module name to the multiplatformModules list in com.intellij.ideaProjectStructure.fast.MultiplatformModuleStructureTest (tests/ideaProjectStructure/testSrc/com/intellij/ideaProjectStructure/fast/MultiplatformModuleStructureTest.kt).
Use only allowed library dependencies. The test enforces a closed set:
kotlin-stdlib
kotlinx-coroutines-core
kotlinx-coroutines-debug
jetbrains-annotations
kotlinx-serialization-core
kotlinx-serialization-json
kotlin-reflect
kotlinx-collections-immutable
If you need a new library, add it to allowedMultiplatformLibraryDependencies in the test. Dependencies on other multiplatform modules (those in multiplatformModules) are also allowed.
Set up source folders:
src/ — common code
srcJvm/ or srcJvmMain/ — JVM-specific code (Java code can live here too)
srcWasmJs/ or srcWasmJsMain/ — WasmJs-specific code
srcJsMain/ — JS-specific code
srcNativeMain/ — Native-specific code
Important: Do NOT add srcWasmJs/srcWasmJsMain as a source root in the .iml file. The IDE would try to compile it in JVM mode.
Add the .pseudoCommonKotlinSourceSet marker file to the common source root (e.g., src/.pseudoCommonKotlinSourceSet). This empty file tells the Kotlin plugin that the source set is common code, preventing Optimize Imports from removing imports that are unnecessary on JVM but mandatory in common code (e.g., @JvmStatic, @JvmField).
IML File Setup
Your .iml file needs two things: the multiplatformSupport dependency and the compiler plugin registration.
Use community/platform/util/multiplatform/intellij.platform.util.multiplatform.iml as a reference. To find the current plugin version, check that file rather than hardcoding.
1. Add the support module dependency (PROVIDED scope)
JVM actual (community/platform/util/base/multiplatform/srcJvmMain/com/intellij/util/text/jvm.kt):
@ActualinternalfungetCharsPlatformSpecificJvm(
string: CharSequence, srcOffset: Int, dst: CharArray, dstOffset: Int, len: Int
): Boolean {
if (string is CharBuffer) { /* ... */ }
returnfalse
}
Code Conversion Notes
The monorepo uses the JVM version of the Kotlin standard library, which differs from the common version. Check which declarations are available in common code.
@JvmStatic, @JvmField, and similar annotations are not auto-imported in common code. Import them manually. The .pseudoCommonKotlinSourceSet marker prevents the IDE from removing these imports.
Java code can remain in platform-specific source sets (srcJvm/).
After Editing
Run ./build/jpsModelToBazel.cmd after modifying any .iml files.
Run MultiplatformModuleStructureTest to validate module structure:
The monorepo does not publish multiplatform artifacts to Maven Central directly. Separate repositories with Gradle infrastructure extract module sources, compile with true KMP, and publish. See fleet-multiplatform-deps and fleet-parser-collection in JetBrains Space.