Re: Best way to create daily SNAPSHOT updates in autoupdate center?

William Winder <[email protected]> Tue, 22 Aug 2017 12:01:08 -0400
Newsgroups gmane.comp.java.netbeans.modules.openide.devel
Message-ID <CAJYutcgqYr+MkvgeXYQhU+RdJQBS7PW-xZSJwZuMHdUKZJk0Yg@mail.gmail.com>
The actual implementation is on github. It works exactly the way I hoped it
would. The main downside is that I'll need to remember to configure every
plugin manifest to include "OpenIDE-Module-Implementation-Version".

Add filtering to manifest files:
https://github.com/winder/Universal-G-Code-Sender/commit/9472bfa508e6432f24b1dd0fb2bf6b76f3b79fc8

Parse major/minor/incremental versions out of "1.2.3-SNAPSHOT" and append ".
yyyy.MM.dd.HH.mm":
https://github.com/winder/Universal-G-Code-Sender/commit/225bb2384c05f97847ee4636a1ac7db430019c26

On Tue, Aug 22, 2017 at 11:47 AM, William Winder <[email protected]>
wrote:

> 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.
> ​
>