2009-03-26 4 views
3

my ivysettings.xml 파일에 다음 내용이 포함되어있는 경우 :Apache Ivy는 ivysettings.xml 파일에 제공된 이슈 패턴의 변수를 어떻게 해결합니까?

<url name="com.springsource.repository.bundles.external"> 
    <ivy pattern="http://repository.springsource.com/ivy/bundles/external/[organisation]/[module]/[revision]/[artifact]-[revision].[ext]" /> 
    <artifact pattern="http://repository.springsource.com/ivy/bundles/external/[organisation]/[module]/[revision]/[artifact]-[revision].[ext]" /> 
</url> 

그리고 내 ivy.xml 파일에는 다음이 포함됩니다.

<dependency org="org.junit" 
      name="com.springsource.org.junit" 
      rev="4.4.0" /> 

아이비를 실행했을 때 다음과 같이 해결할 수 있습니다. http://repository.springsource.com/ivy/bundles/external/org.junit/com.springsource.org.junit/4.4.0/com.springsource.org.junit-sources-4.4.0.jar

그래서 해상도는 다음과 같습니다.

[organization] => "org.junit" 
[module] => "com.springsource.org.junit" 
[revision] => "4.4.0" 
[artifact] => "com.springsource.org.junit-sources" 
[ext] => "jar" 

아이비가 URL 패턴에서 [organization], [module] 및 [revision]을 어떻게 해결하는지 알 수 있지만 어떻게 [artifact]와 [ext ]?

documentation on the URL resolver이 부족한 것 같습니다.

답변

6

Ivy는 조직, 모듈 및 수정 버전이 제공되고 [artifact]이 "ivy"로 하드 코드되고 이 "xml"로 하드 코드 된 상태로 먼저 해결합니다. 이것은이 경우에는 URL을 산출 :

http://repository.springsource.com/ivy/bundles/external/org.junit/com.springsource.org.junit/4.4.0/ivy-4.4.0.xml

이이 모듈에 대한 담쟁이 구성 파일입니다. 무엇보다도,이 담쟁이 구성 파일은 특히, 다른 유물에 대한 정보가 포함되어 있습니다 :이 두 가지가 다음 <artifact pattern... /> 부분을 완료하는 데 사용되는

<artifact name="com.springsource.org.junit-sources" type="src" ext="jar"/> 
<artifact name="license" type="license" ext="txt"/> 

- 라이센스를 다운로드하고 jar 파일을 다운로드 할 수 있습니다.

관련 문제