Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ability to use a package release number #215

Open
laeti-tia opened this issue Jul 1, 2015 · 3 comments
Open

Ability to use a package release number #215

laeti-tia opened this issue Jul 1, 2015 · 3 comments
Milestone

Comments

@laeti-tia
Copy link

Is there a way I can have a package release number being used by jdeb?

I'd like to be able to version my Debian packages with a scheme such as:

  • 1.5.1**-1**~20150701123456
  • 1.5.1**-1**
  • 1.5.1**-2**
  • 1.5.2**-1**

The number after the - is this release number, it would only change when there is a change in the Debian package but nothing has changed in the source code or any configuration files. This is a regular practice in the Debian packaging world.

I can use a property in my pom.xml file to track this release number, but how can I use in the package version generated? I've looked at the documentation but couldn't find any way to make such a versionning pattern.

Does that exists in some way? If not, consider this a feature request. :-)

Thanks.

@RockyMM
Copy link

RockyMM commented Jul 1, 2015

I looked as well, the only thing that looks remotely similar are snapshotExpand and snapshotEnv options, but SNAPSHOT expansion is happening after "tilde" and this should be happening in the middle of version string. And this versioning scheme is needed for both releases and snapshots.

For release version [[version]] expansion could be used along with user defined property from pom.xml, but for snapshots there is not really easy way to do this.

@tcurdt tcurdt added this to the 1.5 milestone Oct 10, 2015
@tcurdt tcurdt modified the milestones: 2.0, 1.5 Jan 16, 2016
@tcurdt
Copy link
Owner

tcurdt commented Jan 16, 2016

I think tracking these kind of changes is out of scope for jdeb. You could define a variable and pass it from maven/ant - but we would then have allow to configure the version string better. I guess that's 2.x material.

As a workaround you could modify the [[buildDir]]/[[artifactId]]_[[version]]_all.[[extension]] pattern and provide your own version instead. Not sure I am thinking of all corner cases - but I guess that could work.

@lathspell
Copy link

I have a similar problem as I release quite often for small changes and have versions like: target/foo-20160503T152414-5a8b795.jar i.e. ${timestamp}-${buildNumber}.

It would be great if the [[version]] tag from src/deb/control/control could simply be set in the pom.xml like:

                    <configuration>
                        <verbose>true</verbose>
                        <version>${timestamp}-${buildNumber}</version>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants