Probably a stupid question … but how does one writ...
# compiler
Probably a stupid question … but how does one write a custom compiler plugin for Kotlin? Background: we have a custom plugin for the Java compiler, that we use to insert copy right information into each of our class files. We want to allow for kotlin source code in our next project, and ideally: do the same thing there. So, what would be a good way to go about that? I only found this page on the official documentation, but that seems to only talk about some existing compiler plugins … not how to write one yourself?!
Honestly, things change and you really need to find an existing one and see what they di
How is the copyright information added? Would an ASM transformer be simpler?
I don’t know, I want to study the source code on the java side tomorrow. Didn’t think of ASM before, I will have a look, too. Thanks for the link!
I don't know exactly what you intend but if it's something straightforward like this, I'd deem doing it in Gradle (either via a hack like this or through proper artifact transform) to be easier to write and maintain than a compiler plugin
Awesome, thank you!