[
https://issues.apache.org/jira/browse/GROOVY-10468?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17486140#comment-17486140
]
Marcin Zajaczkowski commented on GROOVY-10468:
----------------------------------------------
Big thanks Paul for your comment.
I tried to find a way to set a system property with some API, but I completely
forgot it is global and I can set it...
I was able to compile Spock test with --configscript from command line, so it
addresses the problem. I have some problems with Idea which seems to ignore the
file, but it is not related to Groovy itself.
To sum it up, maybe it would be worth to convert this ticket into a
documentation task? First, I wanted to do it, but then realized I have almost
nothing about the things above, so probably someone with more extensive
knowledge could do it, once upon a time.
> Ability to define system properties for groovyc using CompilerConfiguration
> ---------------------------------------------------------------------------
>
> Key: GROOVY-10468
> URL: https://issues.apache.org/jira/browse/GROOVY-10468
> Project: Groovy
> Issue Type: New Feature
> Components: Compiler
> Affects Versions: 3.0.9, 4.0.0
> Reporter: Marcin Zajaczkowski
> Priority: Minor
>
> In some cases, it would be useful to be able to define system properties for
> groovyc using CompilerConfiguration.
> The real life example is a limitation of Idea which doesn't allow to provide
> system properties for groovyc (just for javac) -
> [https://youtrack.jetbrains.com/issue/IDEA-287642] . As a result, Spock
> 2.0-groovy-3.0 cannot be easily compiled in Idea if Maven project is imported.
> There are probably also some other situations where CompilerConfiguration
> might be more handy than playing with Gradle/Maven/Ant/Netbeans
> configurations.
--
This message was sent by Atlassian Jira
(v8.20.1#820001)