2017-06-06 5 views

答えて

0

古いmaven-ant-tasksパッケージを使用して、成果物とpomファイルのアップロードを行うことができます。 http://maven.apache.org/ant-tasks/

pomの定義にwritepom関数を使用し、パッケージからartifact:deployタスクを実行するためのターゲットを作成することができます。

本当に簡単な設定方法です。

例:現在、私のbuiuld.xmlファイルのみが耳を作成している

<target name="artifactory-deployment"> 
<artifact_jf:pom id="tmp.pom" groupid="${artifact.groupid}" artifactid="${artifact.name}" version="1.0" packaging="ear" name="${artifact.name}"   /> 
<artifact_jf:writepom pomRefId="tmp.pom" file="pom.xml"/> 
<artifact_jf:deploy file="build/ears/artifact.ear"> 
    <remoteRepository url="http://localhost:8081/artifactory/libs-release-local"> 
     <authentication username="artifactory-username" password="artifactory-password" /> 
    </remoteRepository> 
    <pom file="pom.xml" /> 
</artifact_jf:deploy> 

+0

。 artifactoryにデプロイするためのサンプルbuild.xmlファイルがある場合は、私に提案してください。ここでは、私は何かを理解していないmypom refidとすべてです。 –

+0

ここでshuildはgroupidとartifactIdを書いていますか? –

+0

ここでは、灰色のファイルをm2フォルダにインストールしています [artifact:deploy] Mavenアーティファクトタスクの処理中にエラーが発生しました。 [アーティファクト:デプロイ]診断: [アーティファクト:デプロイ] [アーティファクト:デプロイ] POM要素リポジトリ [アーティファクト:展開]を展開するために必要とされる BUILDが失敗 C:RAD \ WorkspacesV75 \ WAS70を\ \ IafDeploymentSTS9 .0 \ BuildScript \ build.xml:50:POM要素はリポジトリにデプロイする必要があります –

関連する問題