How do I get rid of packaging deprecation warnings when adding a dependency on a WAR?


(Alex McManus) #1

I have a dependency that looks like this (a custom configuration):

webapp group:‘org.demo’, name:‘demo-webapp’, version:‘1.0.0-SNAPSHOT’, type:‘war’, ext:‘war’

I get the following warning:

Relying on packaging to define the extension of the main artifact has been deprecated and is scheduled to be removed in Gradle 2.0

I’ve not been able to find a way of specifying the dependency without getting this warning. BTW, I’m doing post-processing on the WAR in a custom plugin.

Thanks, Alex,


#2

Unfortunately, this is a deprecation warning was probably added in error. There’s no current way in Gradle to remove this warning when consuming a war artifact from Maven. I’m going to downgrade this deprecation warning until we provide a good alternative.

Don’t worry, we won’t remove this functionality without first providing a better way.


#3

I’ve raised GRADLE-2745 to track this issue.


(Alex McManus) #4

Many thanks!