-
Notifications
You must be signed in to change notification settings - Fork 148
Description
I'm submitting a…
- bug report
- feature request
- other
Short description of the issue/suggestion:
Hi there, and many thanks for a great tool.
I need a little help. My RPM packaging fails for SNAPSHOT versions. My project uses java conventions which contain hyphen character in version - e.g. 0.3.4-SNAPSHOT. This trips up RPM packager which doesn't allow hyphens in version. Is there a way to deal with this?
Steps to reproduce the issue/enhancement:
- Take any example project and set version to 1.0.0-SNAPSHOT
- Try to build RPM package
What is the expected behavior?
Maybe for RPM packages we could replace hyphen with underscore?
What is the current behavior?
RPM part of the build fails.
Do you have outputs, screenshots, demos or samples which demonstrate the problem or enhancement?
Build log has this exception trace:
java.lang.IllegalArgumentException: version with value: '0.3.4-SNAPSHOT' contains illegal character -
at org.redline_rpm.Builder.checkVariableContainsIllegalChars (Builder.java:329)
at org.redline_rpm.Builder.setPackage (Builder.java:347)
at org.redline_rpm.Builder.setPackage (Builder.java:359)
at io.github.fvarrui.javapackager.packagers.GenerateRpm.doApply (GenerateRpm.java:57)
at io.github.fvarrui.javapackager.packagers.GenerateRpm.doApply (GenerateRpm.java:22)
at io.github.fvarrui.javapackager.packagers.ArtifactGenerator.apply (ArtifactGenerator.java:44)
at io.github.fvarrui.javapackager.packagers.Packager.generateInstallers (Packager.java:435)
at io.github.fvarrui.javapackager.maven.PackageMojo.execute (PackageMojo.java:371)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:137)
...
What is the motivation / use case for changing the behavior?
RPM builds for snapshots should work?
Please tell us about your environment:
- JavaPackager version: 1.6.0
- OS version: Rocky Linux 8.5
- JDK version: 11
- Build tool:
- Maven
- Gradle
Other information (e.g. related issues, suggestions how to fix, links for us to have context)