Of course, this small tip is common knowledge amongst all developers that use Eclipse as their IDE, but I only recently came across it.
Eclipse doesn't know your real name, and it doesn't provide a way to configure it in the settings panels. The default behavior of Eclipse when inserting JavaDoc comments in your code is to use the system property user.name. This generates code like:
/** * @author dashorst */
or when working with Eclipse at home:
/** * @author martijn */
Instead I want it to generate a comment like:
/** * @author Martijn Dashorst */
Currently I have to go to the author tag and retype the generated name. Now that is not cool. And what I also don't want to do is to change the templates that are provided by Eclipse. So, instead: I altered the eclipse.ini file, which you probably already have changed to increase the available memory and have these values:
-vmargs -Xms128m -Xmx512m -Duser.name=Martijn Dashorst
The last parameter is the one that this tip concerns.
Define the user.name system property at startup of Eclipse and presto! The name of your choosing will always be correct!