altavir
04/14/2019, 5:19 PMgildor
04/17/2019, 3:56 AMaltavir
04/23/2019, 7:02 AMgildor
04/23/2019, 7:03 AMaltavir
04/23/2019, 7:06 AMgildor
04/23/2019, 7:06 AMIt does not workIt works, I showed it in my sample
gildor
04/23/2019, 7:06 AMbut in dev branch I have to use node plugin for js testsI will send you sample of this later
altavir
04/23/2019, 7:07 AMgildor
04/23/2019, 7:07 AMI can’t understand how those plugins blocks are loaded and where should I declare the versionIf you use this plugin in buildSrc you should define version in buildSrc/build.gradle dependencies
altavir
04/23/2019, 7:07 AMgildor
04/23/2019, 7:08 AMgildor
04/23/2019, 7:08 AMgildor
04/23/2019, 7:09 AMaltavir
04/23/2019, 7:09 AMgildor
04/23/2019, 7:09 AMgildor
04/23/2019, 7:09 AMaltavir
04/23/2019, 7:10 AMgildor
04/23/2019, 7:14 AMartifactory
plugin, which is purely dynamic, for some reason publishBuildInfo
property doesn’t workaltavir
04/23/2019, 7:14 AMgildor
04/23/2019, 7:16 AMgildor
04/23/2019, 7:27 AMRealLUSolverTest > testInvert
is falling for me, but I don’t think that it’s build config problemaltavir
04/23/2019, 7:28 AMaltavir
04/23/2019, 7:32 AMaltavir
04/23/2019, 7:33 AMgildor
04/23/2019, 7:36 AMgildor
04/23/2019, 7:36 AMaltavir
04/23/2019, 7:37 AMgildor
04/23/2019, 7:37 AMgildor
04/23/2019, 7:38 AMplugins
block is exactly this explicit script receiver that defines classpath of the scriptaltavir
04/23/2019, 7:40 AMgildor
04/23/2019, 7:41 AMaltavir
04/23/2019, 7:43 AMProject
instance, but in some cases it could be a plugin configuration class like KotlinMultiplatformExtension
if I am running script inside appropriate block. There could be multiple implicit receivers in one scriptgildor
04/23/2019, 7:44 AMgildor
04/23/2019, 7:44 AMKotlinMultiplatformExtension
is not requiredgildor
04/23/2019, 7:44 AMgildor
04/23/2019, 7:45 AMgildor
04/23/2019, 7:45 AMif I am running script inside appropriate blockAgain, if you just need some context, why not just use extension function for this context, why do you want use
include
for thisaltavir
04/23/2019, 7:45 AMgildor
04/23/2019, 7:46 AMaltavir
04/23/2019, 7:46 AMaltavir
04/23/2019, 7:46 AMgildor
04/23/2019, 7:46 AMinclude
as in any other Kotlin codegildor
04/23/2019, 7:47 AMWhat will happen when you try to apply mpp configuration in wrong pluginBut this checked on build script compile time, not even on runtime
gildor
04/23/2019, 7:47 AMgildor
04/23/2019, 7:48 AMaltavir
04/23/2019, 7:49 AMapply(plugin = "multiplatform-config")
outside plugin check and got completely uncomprehensible error in kotlin-jvm plugin.gildor
04/23/2019, 7:50 AMgildor
04/23/2019, 7:50 AMmultiplatform-config
to every module explicitlygildor
04/23/2019, 7:50 AMgildor
04/23/2019, 7:51 AMkotlin("jvm")
and kotlin("multiplatform")
altavir
04/23/2019, 7:51 AMgildor
04/23/2019, 7:51 AMgildor
04/23/2019, 7:51 AMgildor
04/23/2019, 7:52 AMaltavir
04/23/2019, 7:57 AM[ Project, KotlinMultiplatformExtension]
. Now I want to seamlessly move some logic from this block into external script (not necessary precompiled). All I need is to tell this script which receivers to expect and it could work as if the code was right there in the initial file. Also, when we call the script, we can statically check if declared receivers correspond to actual receivers at call site. The class-path is different problem.gildor
04/23/2019, 8:00 AMIt has a set of explicit receivers like[ Project, KotlinMultiplatformExtension]
fun Project.configureMpp(kotlin: KotlinMultiplatformExtension)
altavir
04/23/2019, 8:01 AMimplicitReceivers
feature to it maximum power.gildor
04/23/2019, 8:02 AMgildor
04/23/2019, 8:04 AMgildor
04/23/2019, 8:05 AMbuild-config-refactoring-dev
with your changes from dev to fix conflicts and some additional changes, such as replacing kotlin(“multiplatform”) with id(“multiplatform-config”), so we don’t need this check in submodulesaltavir
04/23/2019, 8:05 AMgildor
04/23/2019, 8:07 AMgildor
04/23/2019, 8:12 AMaltavir
04/23/2019, 8:14 AMgildor
04/23/2019, 8:15 AMgildor
04/23/2019, 8:15 AMgildor
04/23/2019, 8:15 AM<https://youtrack.jetbrains.com/issue/KT-31021>
gildor
04/23/2019, 8:16 AMfun Project.configureMpp(kotlin: KotlinMultiplatformExtension)
something like that
fun (Project, KotlinMultiplatformExtension).configureMpp()
gildor
04/23/2019, 8:16 AMaltavir
04/23/2019, 8:16 AMgildor
04/23/2019, 8:17 AMaltavir
04/23/2019, 8:19 AMgildor
04/23/2019, 8:23 AMgildor
04/23/2019, 8:25 AMgildor
04/23/2019, 9:52 AMaltavir
04/23/2019, 10:07 AMgildor
04/23/2019, 10:09 AMgildor
04/23/2019, 10:09 AMaltavir
04/23/2019, 10:10 AMgildor
04/23/2019, 10:10 AMaltavir
04/23/2019, 10:11 AMgildor
04/23/2019, 10:12 AMgildor
04/23/2019, 10:12 AMgildor
04/23/2019, 10:12 AMgildor
04/23/2019, 10:13 AMaltavir
04/23/2019, 10:14 AMgildor
04/23/2019, 10:16 AMgildor
04/23/2019, 10:16 AM