In pom.xml I have set o profiles like this:
<profile>
<id>profileId1</id>
    <build>
        <filters>
            <filter>src/main/filters/profileId1.properties</filter>
        </filters>
// rest of the profile 
</profile>
<profile>
<id>profileId2</id>
    <build>
        <filters>
            <filter>src/main/filters/profileId2.properties</filter>
        </filters>
// rest of the profile
</profile>
Is there any way I could extract this piece from all the profiles, so there is no need to repeat this for every profile (and possibly misspell it)?