在学习Spring自带的文档MVC Step by step过程中,遇到了例子中的Ant文件编译不过的情况
build.properties
# Ant properties for building the springapp
appserver.home=${user.home
}/apache-tomcat-6.0.14
# for Tomcat 5 use $appserver.home}/server/lib
# for Tomcat 6 use $appserver.home}/lib
appserver.lib=${appserver.home}/lib
deploy.path=${appserver.home}/webapps
tomcat.manager.url=http://localhost:8080/manager
tomcat.manager.username=tomcat
tomcat.manager.password=s3cret
其中的user.home并未配置
查找了一下,应该是指向
<property file="${user.home}/.ant-global.properties"/>
since the "user.home" property is defined by the Java virtual machine to be your home directory. Where the "user.home" property resolves to in the file system depends on the operating system version and the JVM implementation. On Unix based systems, this will map to the user's home directory. On modern Windows variants, this will most likely resolve to the user's directory in the "Documents and Settings" folder. Older windows variants such as Windows 98/ME are less predictable, as are other operating system/JVM combinations.
看了报错,果然如此。
在学习Spring MVC的过程中,遇到Ant构建文件无法编译的问题。主要原因是build.properties中引用了未配置的user.home属性,该属性由JVM定义为用户的主目录。
1090

被折叠的 条评论
为什么被折叠?



