开发者

Remove the comment "Generated by Javadoc on <date> <time>" in generated Javadoc

开发者 https://www.devze.com 2023-02-24 04:06 出处:网络
A javadoc command automatically inserts a comment stating something like: <!-- Generated by javadoc (build 1.6.0_17) on Thu Apr 07 18:32:31 CEST 2011 -->

A javadoc command automatically inserts a comment stating something like:

<!-- Generated by javadoc (build 1.6.0_17) on Thu Apr 07 18:32:31 CEST 2011 -->

in every generated HTML file.

This is quite prevent开发者_如何学JAVAing change tracking for versioned javadoc, since every file will be modified when regenerating the doc.

A previous question I asked convince me not to version any javadoc, but it also raised this problem and the question remains: is there a way to get rid of this comment? I did not find trace of such possibility in the javadoc options.


Thank to JackMc's comment, I found the command line parameter -notimestamp. It works (at least for my 1.6.0_20 here).

If using ant, you'll have to add it to the <javadoc> task using either the <arg value="-notimestamp" /> nested element or an additionalparam="-notimestamp" attribute.

(I just used this for my github-managed JSch documentation..)

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号