Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Newcomers » Newcomers » Auto generating build number in Eclipse
Auto generating build number in Eclipse [message #188489] Tue, 16 January 2007 23:09 Go to next message
Eclipse UserFriend
Originally posted by: fshsweden.hotmail.com

I just started with Eclipse/Java. This is probably a FAQ, but I just
can't find the answer....

How can I get a build-number automatically generated for my project?
Either as a constant in a java-file or a resource/property of some kind.

Thanks in advance for any pointers!
//Peter
Re: Auto generating build number in Eclipse [message #188574 is a reply to message #188489] Wed, 17 January 2007 08:55 Go to previous message
Eclipse UserFriend
Originally posted by: jacek.pospychala.gmail.com

You can make use of ant.
In your project properties, on Builders tab add new builder, choose Ant
Build, and choose your Build file.

For generating build number it might look like this:
<?xml version="1.0"?>
<project name="project" default="default">
<target name="default">
<buildnumber file="file.with.buildnumber"/>
</target>
</project>

Note that by default builder is launched only for complete builds
(launched from Project menu), and not for auto builds (on every file
change). You can customize it in builder properties.

Jacek

Peter Andersson napisał(a):
> I just started with Eclipse/Java. This is probably a FAQ, but I just
> can't find the answer....
>
> How can I get a build-number automatically generated for my project?
> Either as a constant in a java-file or a resource/property of some kind.
>
> Thanks in advance for any pointers!
> //Peter
Previous Topic:Shortcut to view a file in the finder
Next Topic:Automatic Perspective Switch
Goto Forum:
  


Current Time: Thu Apr 25 09:59:04 GMT 2024

Powered by FUDForum. Page generated in 0.08442 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top