Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [tycho-user] about.ini with qualifier/snapshot

Hi Greg,

You can use Maven resource filtering. It is dangerous to use in general, but I enabled it for one file only (I hope :)).

Here is how I display the version of my RCP app in the about dialog. In my plugin.properties I have :

 

aboutText=\n\My company\n\

\n\

Version: {0}\n\

Build:   {1}\n\

\n\

 

I have about.mappings file with content:

 

0=${unqualifiedVersion}

1=${unqualifiedVersion}.${buildQualifier}

 

I could replace them in the plugin.properties directly, but I prefer to “decouple” by using about.mappings file.

 In my plugin pom.xml   where the about.mappings is, (not the parent)  I specify:

 

<build>

<resources>

      <resource>

        <directory>.</directory>

        <filtering>true</filtering>

        <includes>

          <include>about.mappings</include>

        </includes>

      </resource>    

    </resources>

</build>

 

This will replace the properties in the target, not the original file.


Penka


Back to the top