Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

增强 template.path 和 compile.path 的配置功能 #57

Closed
subchen opened this issue Dec 18, 2013 · 0 comments
Closed

增强 template.path 和 compile.path 的配置功能 #57

subchen opened this issue Dec 18, 2013 · 0 comments
Assignees
Milestone

Comments

@subchen
Copy link
Owner

subchen commented Dec 18, 2013

目前 template.pathcompile.path 只能配置成绝对路径。

虽然相对路径也是支持的,但是相对路径可能会发生变化,存在不确定性,一般不建议使用。

template.path 在 web 集成模式中,会被限定在 webapp 目录下。而 compile.path 无法配置在 webapp 目录下。

现在要求能够把 compile.path 也能够配置在 webapp 目录下面。

具体配置如下:

template.path = ${webapp.dir}/WEB-INF/jetx/templates
compile.path = ${webapp.dir}/WEB-INF/jetx/classes

主要增加对 System.getProperties() 环境变量的支持。

如:

${user.dir}
${java.io.tmp}
${webapp.dir}

为了保持向后兼容性,在 web集成中,将启用新的 JetWebResourceLoader,默认配置如下:

template.loader = jetbrick.template.web.WebResourceLoader
template.path = /

以后如果在有相同需要配置 path,都启用变量支持。

@ghost ghost assigned subchen Dec 18, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant