开发者

how can i know whether i am using a snapshot version or not

开发者 https://www.devze.com 2023-04-09 13:09 出处:网络
I have created my own repository under my hard disk using Apache Server and provided username and password under settings.xml file

I have created my own repository under my hard disk using Apache Server and provided username and password under settings.xml file under the M2_HOME

And when i am running mvn deploy under command prompt its displaying BUILD ERROR 开发者_如何学Csaying this

<distributionManagement>
  <!-- use the following if you're not using a snapshot version. --
  <repository>
    <id>repo</id>
    <name>Repository Name</name>
    <url>scp://host/path/to/repo</url>
  </repository>
  <!-- use the following if you ARE using a snapshot version. -->
  <snapshotRepository>
    <id>repo</id>
    <name>Repository Name</name>
    <url>scp://host/path/to/repo</url>
  </snapshotRepository>
</distributionManagement>

Please tell me how can i know whether i am using a snapshot version (I have imported an existing Maven project into Eclipse , i dont know about maven )


You just have to check in the same pom.xml file of the project whether the <version \> tag includes the -SNAPSHOT suffix. If the ${project.version} is not defined, look for the same tag under the <parent \> tag.

Anyway, you are going to have some hard time setting up deployment with no previous knowledge of Maven. I suggest you take a look at this free PDF guide, which is a pretty good introduction to the tool.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号