Bamboo 版本控制

发布于 2024-08-05 12:43:18 字数 179 浏览 3 评论 0原文

我遇到一种情况,我需要维护我的构建的版本信息。通过谷歌搜索,我发现信息有限。一种方法是在源代码管理上创建版本文件并不断更新。另一种是使用源代码控制修订号。最后一种是使用竹子构建号。我以前没有实施过任何人。任何人都可以指出每种方法的优缺点。

谢谢你, 雷迪。

请至少告诉我您使用哪种方法来实现相同的目的。 恩克..

I have a situation where i need to maintain version information of my builds. By googling i found limited information. one way is to create a version file on source control and keep updating. other is to use the source control revision number. final one is to use bamboo build number. i haven't implemented anyone of this before. colud anyone point out the pros and cons of each method.

Thank you,
Reddy.

Please atleast tell me which method have u used to implement the same.
Thnq..

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(5

岁月染过的梦 2024-08-12 12:43:18

访问http://confluence.atlassian.com/display/BAMBOO011/ 1.2.1+使用+自定义+变量了解有关bamboo变量的更多信息。
请记住在作业配置中定义系统属性,如下所示:
-DbambooBuildNumber=${bamboo.buildNumber} 那么您可以在 maven 或 ant 配置文件中使用此属性 bambooBuildNumber

Visit http://confluence.atlassian.com/display/BAMBOO011/1.2.1+Using+Custom+Variables for more information about bamboo variables.
Remember to define a system property in your job configuration like this:
-DbambooBuildNumber=${bamboo.buildNumber} then you can use this property bambooBuildNumber in your maven or ant configuration file.

鸢与 2024-08-12 12:43:18

好问题。我以前曾以某种临时方式完成过此操作。我并不强烈提倡以下方法,但无论如何我都会列出它,以便与其他人很快发布的(我希望)更好的方法进行比较。

为了维护中型 Java 代码库中的版本信息,我创建了一个简单的类来将主要版本号、次要版本号和修订版本号保存为静态常量,并生成格式化的版本字符串。然后,我创建了一个 perl 脚本来将该类从版本控制中检出,将版本组件替换为指定为脚本参数的版本组件,然后将其重新签入。

该脚本完成了大部分工作,因此更新版本的过程是相当简单快捷。我必须快速实现这一点,所以可能有更好的方法来做到这一点。我只是没有时间或动力去研究更好的替代方案。

Good question. I've done this in kind of an ad-hoc manner before. I don't strongly advocate the following approach, but I'll list it anyway for comparison with the (I hope) better approaches that others will soon be posting.

In order to maintain the version information in a medium sized Java codebase, I created a simple class to hold the major, minor, and revision version numbers as static constants and produce a formatted version string. I then created a perl script to check the class out of version control, replace the version components with those specified as arguments to the script, and check it back in.

The script does most of the work, so the process of updating the version is fairly simple and quick. I had to implement this quickly, so there are probably better ways of doing it. I just didn't have time, or motivation, to research better alternatives.

甜尕妞 2024-08-12 12:43:18

我不完全确定你的问题是什么,但我假设你想要构建编号?当您使用 Ant 构建项目时,您可以使用 BuildNumber 任务来跟踪内部版本号。

I'm not entirely sure what your question is but I'm assuming you want build numbers? When you build your project with Ant you can use the BuildNumber task to keep track of build numbers.

聊慰 2024-08-12 12:43:18

你可以在 ant 中使用 ${bamboo.buildNumber}

看看下面的线程
http://forums.atlassian.com/thread.jspa?messageID=257319944

you can use ${bamboo.buildNumber} in ant

look at the following thread
http://forums.atlassian.com/thread.jspa?messageID=257319944

北斗星光 2024-08-12 12:43:18

下面的链接是一篇非常好的文章。如果您可以让所有插件与您所使用的 Bamboo 版本一起使用,那就没问题了。

使用 Atlassian Bamboo 进行发布管理(已过时)

通过 Internet Archive 使用 Atlassian Bamboo 进行发布管理

The following link is a pretty good article. If you can get all the plugins working with the version of Bamboo you're on it should be fine.

Release Management with Atlassian Bamboo (outdated)

Release Management with Atlassian Bamboo via the Internet Archive

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文