I'm trying to pass a path parameter to my plugin t...
# arrow-meta
d
I'm trying to pass a path parameter to my plugin to work around the
kotlin/daemon
path issue, is this the right syntax? I can't find any references to doing this in the context of arrow meta. I'm getting a build error (the path matches what's found in
META-INF/services/org.jetbrains.kotlin.compiler.plugin.ComponentRegistrar
): e: Invalid argument: -P plugincom.abcd.MetaPluginbuildPath=qwerasdf Is there also something I need to do in the quote syntax to make this work? Also does anyone know where this will show up, just in the
compilerContext.configuration
object? Just to clarify the syntax I'm using is
-P plugin:<path-to-plugin>:param=value
r
Hi Derek, if it's too work around the path issue and you'd like to fix it straight in meta we can help you find out the place where we can replace absolute paths to support also relative paths if you are up for a PR. We plan on adding this fix before release at some point and also we need to add support for plugin args in meta. At the moment things like system properties had been abused for that since the path is the only arg that the current meta plugins need.
d
I probably have a little time to help with meta if that's the best way to fix it, and I'm happy to contribute to a library that I'm putting to use (I might have time in about 5 hours, but more likely over the weekend). I currently have a hack in place looking for directories to try and figure out the gradle variant, but I'd like to avoid putting that in production if at all possible ๐Ÿ˜› My tentative exploration of the issue during debugging implied that the "bad" paths are coming from the compiler side (
System.properties
references the bad path for example).
r
Hi! ๐Ÿ‘‹ The fix is ready for review; https://github.com/arrow-kt/arrow-meta/pull/779
๐Ÿ‘ 1
d
Oh wow, definitely going to take a look at the branch and see if it fixes things.
๐Ÿ‘ 1
This seems to have fixed my path problem and lets me get rid of the hack I had in place ๐Ÿ™‚
๐Ÿ‘ 1
r
Happy to know about it @dalexander, thank you so much for letting us know!! ๐Ÿ™Œ
๐Ÿ‘ 1