how are you using Detekt on multiplatform projects these days? I was hoping to find a
single task that would sweep my entire project but from what I see this doesn’t exist and is being tracked
here, so the options I see are:
• create this task myself (any directions on how I could do that?)
• do something like
this, it seems to work great (basically setting the module root to be the source so all source sets are considered)
• run multiple tasks:
◦
detektMain
to sweep non-multiplatform stuff with type resolution
◦
detektMetadataMain
to sweep
commonMain
on all modules (found this one
here)
◦
detektAndroidDebug
and
detektAndroidRelease
to sweep Android code in multiplatform modules
◦ …and how do I sweep iOS code in multiplatform modules? I’ve tried
detektMetadataIosMain
,
detektIosX64Main
,
detektIosArm64Main
and
detektIosSimulatorArm64Main
but they all seem to fail to find issues on code inside
iosMain
— should I file an issue or am I missing something? I have a minimum reproducible example here:
https://github.com/tfcporciuncula/detekt-kmm-issue (
this commit summarizes everything)
• any other option?