有follwong塊從pom.xml
:Maven的POM systemProperty文件路徑語法
<systemProperty>
<name>axis2.config</name>
<value>file:${project.build.directory}/../../axis2.properties</value>
</systemProperty>
什麼語法value
標記是什麼意思?
/../
- 是id cd ..
並轉發到父目錄?
有follwong塊從pom.xml
:Maven的POM systemProperty文件路徑語法
<systemProperty>
<name>axis2.config</name>
<value>file:${project.build.directory}/../../axis2.properties</value>
</systemProperty>
什麼語法value
標記是什麼意思?
/../
- 是id cd ..
並轉發到父目錄?
短:../
意味着父豬病
長版:
file:
指定,以下g 內容應解釋爲 文件路徑。${project.build.directory}
是 變量,它由 與實際項目 生成目錄中運行時替換/
是文件夾分隔..
意味着父文件夾axis2.properties
是 性文件的名稱如果您想顯示用於調試目的的路徑,您可能想要看看這個:
http://www.avajava.com/tutorials/lessons/how-do-i-display-the-value-of-a-pom-xml-element.html
或
哦,感謝您Alois.is可以看到整個路徑樣子?我的意思是顯示這個變量值,也許在out.println的某個地方? – sergionni 2011-03-16 13:53:27
我不這麼認爲,但是如果你的項目構建目錄在/ home/sergio/projects/myproject/target - > /home/sergio/projects/axis2.properties – 2011-03-16 13:55:36
你可以在這裏找到更多的信息: http://docs.codehaus.org/display/MAVENUSER/MavenPropertiesGuide希望有幫助! – 2011-03-16 13:56:21