eclipse修改默认的author

1. 在eclipse.ini中添加
-vmargs
-Duser.name={author name}
记得必定要在-vmargs以后,不然无效。

2. 设置eclipse参数
windows-->preference 
Java-->Code Style-->Code Templates 
code-->new Java files
原来的内容是:
${filecomment} 
${package_declaration} 

${typecomment} 
${type_declaration}
添加自定义内容,添加以后内容以下:
${filecomment} 
${package_declaration} 
/** 
* @author 做者 E-mail: 
* @version 建立时间:${date} ${time} 
* 类说明 
*/ 
${typecomment} 
${type_declaration}

3. 设置eclipse参数
windows-->preference 
Java-->Code Style-->Code Templates 
Comments-->files 
按照须要修改配置,而且保证上面项的配置中有${filecomment}这项。windows

相关文章
相关标签/搜索