mavenLocal() in Grails 2.3.4 with aether

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

mavenLocal() in Grails 2.3.4 with aether

rlovtangen

The default template when creating new Grails 2.3.4 plugins or applications both have mavenLocal() enabled under repositories.
Does that have any effect at all when using aether?

From my testing it doesn't. And I guess it's kind of wouldn't make sense either, in the same way that there was no way under ivy to say if you wanted to use the local cache under ~/.grails/ivy-cache. And why should it.
Under ivy, the meaning of mavenLocal() was "copy dependencies from my maven cache (~/.m2/repos) to my grails ivy cache (~/.grails/ivy-cache).
Now that grails' dependency cache is ~/.m2/repos, including mavenLocal() under repositories doesn't make sense. Right?

My proposal is to remove it from the template. Any thoughts on that?

Ronny
---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply | Threaded
Open this post in threaded view
|

Re: mavenLocal() in Grails 2.3.4 with aether

rlovtangen
Am I right that mavenLocal() only applies to ivy, not aether?

Best Regards,
Ronny


On 02 Jan 2014, at 22:10, Ronny Løvtangen <[hidden email]> wrote:

>
> The default template when creating new Grails 2.3.4 plugins or applications both have mavenLocal() enabled under repositories.
> Does that have any effect at all when using aether?
>
> From my testing it doesn't. And I guess it's kind of wouldn't make sense either, in the same way that there was no way under ivy to say if you wanted to use the local cache under ~/.grails/ivy-cache. And why should it.
> Under ivy, the meaning of mavenLocal() was "copy dependencies from my maven cache (~/.m2/repos) to my grails ivy cache (~/.grails/ivy-cache).
> Now that grails' dependency cache is ~/.m2/repos, including mavenLocal() under repositories doesn't make sense. Right?
>
> My proposal is to remove it from the template. Any thoughts on that?
>
> Ronny
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>    http://xircles.codehaus.org/manage_email
>
>
>


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply | Threaded
Open this post in threaded view
|

Re: mavenLocal() in Grails 2.3.4 with aether

pledbrook
If you look at the Aether implementation, you'll see that most of the
repository labels you've mentioned in various places are basically
no-op implementations:

    https://github.com/grails/grails-core/blob/2.3.x/grails-aether/src/main/groovy/org/codehaus/groovy/grails/resolve/maven/aether/config/RepositoriesConfiguration.groovy

So yes, they only have an effect when Ivy is used as the dependency resolver.

I think http://repo.grails.org/grails/core was removed because the
main Grails dependencies are published to Maven Central. That
unfortunately leaves our custom Compass JAR rather stranded. I may
move it to Bintray.

Peter


On 6 January 2014 15:19, Ronny Løvtangen <[hidden email]> wrote:

> Am I right that mavenLocal() only applies to ivy, not aether?
>
> Best Regards,
> Ronny
>
>
> On 02 Jan 2014, at 22:10, Ronny Løvtangen <[hidden email]> wrote:
>
>>
>> The default template when creating new Grails 2.3.4 plugins or applications both have mavenLocal() enabled under repositories.
>> Does that have any effect at all when using aether?
>>
>> From my testing it doesn't. And I guess it's kind of wouldn't make sense either, in the same way that there was no way under ivy to say if you wanted to use the local cache under ~/.grails/ivy-cache. And why should it.
>> Under ivy, the meaning of mavenLocal() was "copy dependencies from my maven cache (~/.m2/repos) to my grails ivy cache (~/.grails/ivy-cache).
>> Now that grails' dependency cache is ~/.m2/repos, including mavenLocal() under repositories doesn't make sense. Right?
>>
>> My proposal is to remove it from the template. Any thoughts on that?
>>
>> Ronny
>> ---------------------------------------------------------------------
>> To unsubscribe from this list, please visit:
>>
>>    http://xircles.codehaus.org/manage_email
>>
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>     http://xircles.codehaus.org/manage_email
>
>



--
Peter Ledbrook
t: @pledbrook

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply | Threaded
Open this post in threaded view
|

Re: mavenLocal() in Grails 2.3.4 with aether

rlovtangen
Ah, I was tricked by navigation in IntelliJ that took me to org.codehaus.groovy.grails.resolve.config.RepositoriesConfigurer used by Ivy, not org.codehaus.groovy.grails.resolve.maven.aether.config.RepositoriesConfiguration used by aether.

It's quite obvious then that the template for BuildConfig.groovy should remove these repos:

        grailsPlugins()
        grailsHome()
        mavenLocal()

Or at least comment them out with an additional comment that they only applies to Ivy.
I'll see if I get the time to add a pull request.

Ronny

On 09 Jan 2014, at 11:21, Peter Ledbrook <[hidden email]> wrote:

> If you look at the Aether implementation, you'll see that most of the
> repository labels you've mentioned in various places are basically
> no-op implementations:
>
>    https://github.com/grails/grails-core/blob/2.3.x/grails-aether/src/main/groovy/org/codehaus/groovy/grails/resolve/maven/aether/config/RepositoriesConfiguration.groovy
>
> So yes, they only have an effect when Ivy is used as the dependency resolver.
>
> I think http://repo.grails.org/grails/core was removed because the
> main Grails dependencies are published to Maven Central. That
> unfortunately leaves our custom Compass JAR rather stranded. I may
> move it to Bintray.
>
> Peter
>
>
> On 6 January 2014 15:19, Ronny Løvtangen <[hidden email]> wrote:
>> Am I right that mavenLocal() only applies to ivy, not aether?
>>
>> Best Regards,
>> Ronny
>>
>>
>> On 02 Jan 2014, at 22:10, Ronny Løvtangen <[hidden email]> wrote:
>>
>>>
>>> The default template when creating new Grails 2.3.4 plugins or applications both have mavenLocal() enabled under repositories.
>>> Does that have any effect at all when using aether?
>>>
>>> From my testing it doesn't. And I guess it's kind of wouldn't make sense either, in the same way that there was no way under ivy to say if you wanted to use the local cache under ~/.grails/ivy-cache. And why should it.
>>> Under ivy, the meaning of mavenLocal() was "copy dependencies from my maven cache (~/.m2/repos) to my grails ivy cache (~/.grails/ivy-cache).
>>> Now that grails' dependency cache is ~/.m2/repos, including mavenLocal() under repositories doesn't make sense. Right?
>>>
>>> My proposal is to remove it from the template. Any thoughts on that?
>>>
>>> Ronny
>>> ---------------------------------------------------------------------
>>> To unsubscribe from this list, please visit:
>>>
>>>   http://xircles.codehaus.org/manage_email
>>>
>>>
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe from this list, please visit:
>>
>>    http://xircles.codehaus.org/manage_email
>>
>>
>
>
>
> --
> Peter Ledbrook
> t: @pledbrook
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>    http://xircles.codehaus.org/manage_email
>
>
>


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply | Threaded
Open this post in threaded view
|

Re: mavenLocal() in Grails 2.3.4 with aether

rlovtangen


I filed a ticket to JetBrains as well for the incorrect code navigation.

Ronny


On 09 Jan 2014, at 11:57, Ronny Løvtangen <[hidden email]> wrote:

Ah, I was tricked by navigation in IntelliJ that took me to org.codehaus.groovy.grails.resolve.config.RepositoriesConfigurer used by Ivy, not org.codehaus.groovy.grails.resolve.maven.aether.config.RepositoriesConfiguration used by aether.

It's quite obvious then that the template for BuildConfig.groovy should remove these repos:

       grailsPlugins()
       grailsHome()
       mavenLocal()

Or at least comment them out with an additional comment that they only applies to Ivy.
I'll see if I get the time to add a pull request.

Ronny

On 09 Jan 2014, at 11:21, Peter Ledbrook <[hidden email]> wrote:

If you look at the Aether implementation, you'll see that most of the
repository labels you've mentioned in various places are basically
no-op implementations:

  https://github.com/grails/grails-core/blob/2.3.x/grails-aether/src/main/groovy/org/codehaus/groovy/grails/resolve/maven/aether/config/RepositoriesConfiguration.groovy

So yes, they only have an effect when Ivy is used as the dependency resolver.

I think http://repo.grails.org/grails/core was removed because the
main Grails dependencies are published to Maven Central. That
unfortunately leaves our custom Compass JAR rather stranded. I may
move it to Bintray.

Peter


On 6 January 2014 15:19, Ronny Løvtangen <[hidden email]> wrote:
Am I right that mavenLocal() only applies to ivy, not aether?

Best Regards,
Ronny


On 02 Jan 2014, at 22:10, Ronny Løvtangen <[hidden email]> wrote:


The default template when creating new Grails 2.3.4 plugins or applications both have mavenLocal() enabled under repositories.
Does that have any effect at all when using aether?

From my testing it doesn't. And I guess it's kind of wouldn't make sense either, in the same way that there was no way under ivy to say if you wanted to use the local cache under ~/.grails/ivy-cache. And why should it.
Under ivy, the meaning of mavenLocal() was "copy dependencies from my maven cache (~/.m2/repos) to my grails ivy cache (~/.grails/ivy-cache).
Now that grails' dependency cache is ~/.m2/repos, including mavenLocal() under repositories doesn't make sense. Right?

My proposal is to remove it from the template. Any thoughts on that?

Ronny
---------------------------------------------------------------------
To unsubscribe from this list, please visit:

 http://xircles.codehaus.org/manage_email





---------------------------------------------------------------------
To unsubscribe from this list, please visit:

  http://xircles.codehaus.org/manage_email





--
Peter Ledbrook
t: @pledbrook

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

  http://xircles.codehaus.org/manage_email





---------------------------------------------------------------------
To unsubscribe from this list, please visit:

   http://xircles.codehaus.org/manage_email