Maven build number plugin, how to save the build number in a file?

后端 未结 4 641
灰色年华
灰色年华 2020-12-24 14:01

I\'ve a Java project using Spring Framework and Git and I wanted to display a build number. I found the Build Number Maven plugin. With Git the build number is a Git hash. I

4条回答
  •  挽巷
    挽巷 (楼主)
    2020-12-24 14:27

    You shouldn't set revisionOnScmFailure option to true, it doesn't expect a boolean. Set it to revision string you want to use when SCM is unavailable, like na or like that. It doesn't matter for your case since you override the build number format but it would be more correct.

    See buildnumber-maven-plugin docs.

提交回复
热议问题