IntelliJ Idea:2016.1 Windows 10 Pro
IntelliJ Idea: 2016.1 Windows 10 Pro
当我在新项目中创建新项目或新类时,IntelliJ有用地包含一个默认标题包含我的姓名和日期。但是,它还会突出显示代码并使用默认文件模板显示有关文件的警告。它提出了两种纠正代码的方法。通过编辑模板或将其替换为实际的文件模板。但是,两种选择都不满足警告;也不会手动替换标题的内容。我无法找到摆脱它的方法。
When I create a new project or a new class in a new project, IntelliJ helpfully includes a default header containing my name and the date. However, it also highlights the code and displays a warning about the file using a "Default File Template". It suggests two ways to correct the code. Either by editing the template or by replacing it with an actual file template. However, neither option satisfies the warning; nor does manually replacing the contents of the header. I can't figure out a way to get rid of it.
我知道我可以取消警告,但我更愿意更正或修正它。
I know that I can suppress the warning, but I would prefer to actually correct or fix it.
任何想法?
推荐答案只需在具有名称和日期的默认模板语句后添加一个新行。 Intellij将新行视为文档的一部分,然后停止投诉。 更新
Just add a new line after Default Template statement which has name and date. Intellij considers that new line as part of documentation, and then stops complaining. Update
赞这个:
/** * Created by YourName on 2017/06/11. * THIS LINE */更多推荐
如何修复或更正“默认文件模板”? IntelliJ Idea中的警告
发布评论