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

可否将静态版本号改为 {revision}变量? #3134

Closed
bjo2008cnx opened this issue Jun 18, 2020 · 8 comments · Fixed by #3151
Closed

可否将静态版本号改为 {revision}变量? #3134

bjo2008cnx opened this issue Jun 18, 2020 · 8 comments · Fixed by #3151

Comments

@bjo2008cnx
Copy link

bjo2008cnx commented Jun 18, 2020

when the version needs to be updated, we need to modify every pom.xml and then commit these files.
Could you please replace version with {revision} variable so that only one file is required to modify? Thanks very much.

@nobodyiam
Copy link
Member

To replace the version of pom.xml, you may use the following commands:
mvn versions:set -DnewVersion=x.x.x -DgenerateBackupPoms=false

@bjo2008cnx
Copy link
Author

Yes. What you say is a very good way to update version. We used to update version in this way.
However, after use :mvn versions:set -DnewVersion=x.x.x -DgenerateBackupPoms=false,
we need to commit too many pom.xml files.

If {revision} variable is used ,ONLY ONE files is needed to commit.
Could you please update it to {revision} ? Thank you very very much.

@bjo2008cnx bjo2008cnx changed the title please replace version with {revision} variable 可否将静态版本号改为 {revision}变量? Jun 28, 2020
@bjo2008cnx
Copy link
Author

做apollo二开好久了,每次合并开源的新版本时,都需要把静态版本号改成${revision}, 重复劳动太多,申请开源版本升级为${revision}变量.(dubbo源码中使用了${revision},可参考)。有同感的同学吧 ?

@bjo2008cnx
Copy link
Author

谢谢宋大佬先!

@nobodyiam
Copy link
Member

This sounds like a good idea, would you please submit a pr for this?

@bjo2008cnx
Copy link
Author

ok.

@bjo2008cnx
Copy link
Author

bjo2008cnx commented Jun 29, 2020

pr 已提交,请大佬review. 详情可对照:FYI: http://maven.apache.org/maven-ci-friendly.html ,非常感谢

@bjo2008cnx
Copy link
Author

宋大佬不屑于review这种小功能啊

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

Successfully merging a pull request may close this issue.

2 participants