Rick schrieb:
> On Thu, May 8, 2008 at 11:56 PM, Wendy Smoak <[EMAIL PROTECTED]> wrote:
>   
>> On Thu, May 8, 2008 at 8:45 PM, Rick <[EMAIL PROTECTED]> wrote:
>>
>> If you have both a <repository> and a <snapshotRepository>, Maven will
>> choose based on whether the version number ends in -SNAPSHOT.  Magic.
>> :)  See 
>> http://maven.apache.org/ref/2.0.9/maven-model/maven.html#class_distributionManagement
>>     
>
> Thanks again Wendy.
>
> Another hopefully quick one... The better builds guide mentions about
> filenames being used with timestamps appended etc, but yet whenever I
> do mvn deploy, I never see that timestamp either in my local m2 repo
> or in my corporate rep snapshots dir, It only ever has the version as
> I've declared in the pom version for the project. I never see
> filenames being created as described below, so I'm wondering if I have
> things set up incorrectly:
>
> <quote page 216 Better Builds With Maven>
> You'll see that it is treated differently than when it was installed
> in the local repository. The filename
> that is used is similar to proficio-api-1.0-20060211.131114-1.jar. In
> this case, the version
> used is the time that it was deployed (in the UTC timezone) and the
> build number. If you were to
> deploy again, the time stamp would change and the build number would
> increment to 2.
>
> This technique allows you to continue using the latest version by
> declaring a dependency on 1.0-
> SNAPSHOT, or to lock down a stable version by declaring the dependency
> version to be the specific
> equivalent such as 1.0-20060211.131114-1. While this is not usually
> the case, locking the
> version in this way may be important if there are recent changes to
> the repository that need to be ignored temporarily.
> </quote>
>   

Try setting this property:
    <uniqueVersion>true</uniqueVersion>
in the distributionManagement/repository section of your pom.

See:
 
http://maven.apache.org/ref/current/maven-model/maven.html#class_distributionManagement

Regards,
Simon


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to