Re: Best way to create daily SNAPSHOT updates in autoupdate center?
William Winder <[email protected]> Tue, 22 Aug 2017 11:47:02 -0400
| Newsgroups | gmane.comp.java.netbeans.modules.openide.devel |
|---|---|
| Message-ID | <CAJYutcgsW+ZF0S9_NoP46KRjyjpP_MaH-2Y8ieyGkveQe=aZfA@mail.gmail.com> |
It is a maven project. I found a roundabout workaround for now but am
hopeful there is a less invasive way to go about it. For example the
proposal described here is exactly what I'm looking for:
http://wiki.netbeans.org/MavenNBM4#Versioning
I updated my manifest.mf files to include the following line:
OpenIDE-Module-Specification-Version:
${ugs.modules.specification.version}
Used the "maven-resources-plugin" resources plugin I copy that file to the
target directory with " <filtering>true</filtering>" to fill make the
substitution.
Making sure the "nbm-maven-plugin" is configured to look there with
"<sourceManifestFile>${project.build.directory}/manifest.mf</sourceManifestFile>"
Now things get a little hacky, I need to parse 1.2.3 out of 1.2.3-SNAPSHOT.
I used the "build-helper-maven-plugin" gives you maven variables like
"${parsedVersion.majorVersion}" and allowed me to define my version like:
<maven.build.timestamp.format>yyyy.MM.dd.HH.mm
</maven.build.timestamp.format>
<ugs.modules.specification.version>
${parsedVersion.majorVersion}.${parsedVersion.minorVersion}.${parsedVersion.incrementalVersion}.${maven.build.timestamp}</ugs.modules.specification.version>
Now everytime I rebuild my snapshot there will be a unique version.