最新为eclipse添加freemarker插件支持

freemarker模板文件可以使用jboss tools下提供的FreeMarker IDE 当前该插件已更新到插件更新至20160428

打开地址:http://freemarker.org/editors.html

我们可以找到如下信息


This is developed as part of the JBoss Tools Project.



Currently (2016-04-23, FreeMarker 2.3.24) it's highly recommended to install the nightly version instead of the official stable. For that, in Eclipse, go to "Help" / "Install New Software...", and copy-paste http://download.jboss.org/jbosstools/neon/snapshots/builds/jbosstools-freemarker_master/latest/all/repo/ into the "Work with" field. Then expand the check box tree appearing below, and select "FreeMarker IDE" only, then "Next", "Next", "Finish". This version works for Eclipse Mars too (probably even for Luna), despite that it's in the Neon branch of JBoss IDE.


此信息已经提示我们,在eclipse中的在线安装的方法

首先请打开我们的软件安装模块:

Help => Install New Software 点击and,再出来的对话框中

name输入:freemarker(名字随意输入即可)

Location输入:http://download.jboss.org/jbosstools/neon/snapshots/builds/jbosstools-freemarker_master/latest/all/repo/

然后会列出来所有可用的插件,我这里选择了全部

[caption id="attachment_979" align="alignnone" width="795"]在线安装freemarker在线安装freemarker[/caption]

然后点击下一步

[caption id="attachment_980" align="alignnone" width="886"]eclipse在线安装freemarkereclipse在线安装freemarker[/caption]

一直点击下一步,这里你需要同意

[caption id="attachment_981" align="alignnone" width="886"]eclipse在线安装freemarkereclipse在线安装freemarker[/caption]

然后等待安装完成

[caption id="attachment_982" align="alignnone" width="606"]eclipse在线安装freemarker eclipse在线安装freemarker[/caption]

最后重启eclipse

退出Eclipse再重启,在window --> Preferences 左边的树形栏里就出现了FreeMarker一项新的内容。

[caption id="attachment_983" align="alignnone" width="627"]freemarker在eclipse中freemarker在eclipse中[/caption]

在General --> Editors --> File Associations下,我们可以看到*.ftl文件的默认编辑器就是FreeMarker,我们可以为*.html和*.htm文件添加(add)FreeMarker作他们关联的编辑器(associated editors) 。这样在编辑混合有HTML和FreeMarker标记的文件时,可以选择右击文件 --> Open with HTML Editor 或者 Open with FreeMarker Editor






爆款云服务器s6 2核4G 低至0.46/天,具体规则查看活动详情Blog Img