Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Maven filtering on resources stored in dependencies

Tags:

spring

maven

Is it possible to have maven filtering applied on resources (such as spring files) that are stored in dependencies?

A spring file in one of my dependent jars uses the property ${project.artifactId}. How can I apply filtering to this spring file so I can import the resource in my local spring file?

like image 710
Josh Avatar asked Feb 16 '12 14:02

Josh


1 Answers

You can unpack the jar first by using the unpack goal in the maven dependency plugin.

You can then apply filtering using the resources plugin.

like image 115
Gaurav Avatar answered Oct 06 '22 00:10

Gaurav