2

I'm trying to put Java comments and I have used for that Java doc tamplate and STS tool : In STS I'm using that configuration in Java doc tamplate:-

/** * Description: * Name of Project: ${project_name} * Created on: ${date} ${time} * Modified on: ${date} ${time} * @author ${user} * Version: 1.0 * ${tags} */ 

Which displays the following on my Java file.

/** * Description: * Name of Project: CabFMS * Created on: Oct 29, 2012 4:05:38 PM * Modified on: Oct 29, 2012 4:05:38 PM * @author tgupta1 * Version: 1.0 */ 

Here, I want to update the version dynamically just like date, time, user, project_name etc.

Please suggest me, is there a way for that or we need to do it manually?

6
  • I'm sorry but at least I cannot follow what you say. Commented Oct 29, 2012 at 12:00
  • Here you may find the answer. stackoverflow.com/questions/2612633/… Commented Oct 29, 2012 at 12:16
  • So do you want the comment to automatically update the version number when someone makes a change? Commented Oct 29, 2012 at 12:18
  • The Cat :Yes you are right i am looking for the same..... Commented Oct 30, 2012 at 4:18
  • Sorry, what is STS? Wikipedia's list doesn't show anything I could recognize as fitting. Commented Nov 4, 2012 at 20:42

1 Answer 1

0

I think the JAutoDoc plugin might help you regenerating all the headers of your source files (if that what you are searching for).

Btw including created/modified/authors can be done easily and automatically with any source versioning systems like SVN, Git or Mercurial. However, their usage is highly discouraged (it simply cause too much noise when diffing).

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.