how can i know whether i am using a snapshot version or not
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.
精彩评论