You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Wim Deblauwe <wi...@gmail.com> on 2010/12/06 13:57:05 UTC

[versions-maven-plugin] Why is the default to generate backup poms?

Hi,

I wonder why the versions-maven-plugin generates backup poms by default? I
would assume that 95% of maven users also uses some kind of version control
system, so I really don't see the need for that.

regards,

Wim

Re: [versions-maven-plugin] Why is the default to generate backup poms?

Posted by Stephen Connolly <st...@gmail.com>.
And versions: rollback reverts

- Stephen

---
Sent from my Android phone, so random spelling mistakes, random nonsense
words and other nonsense are a direct result of using swype to type on the
screen

On 6 Dec 2010 15:38, "Wim Deblauwe" <wi...@gmail.com> wrote:

Did not know about versions:commit, that is nice. I know about the command
line option, but I always forget the exact syntax, so I have to look it up
each time. I have a feeling that I will remember versions:commit more easily
:)

2010/12/6 Stephen Connolly <st...@gmail.com>


> I have considered changing the default so that if the effective pom
> includes
> an SCM section t...

Re: [versions-maven-plugin] Why is the default to generate backup poms?

Posted by Wim Deblauwe <wi...@gmail.com>.
Did not know about versions:commit, that is nice. I know about the command
line option, but I always forget the exact syntax, so I have to look it up
each time. I have a feeling that I will remember versions:commit more easily
:)

2010/12/6 Stephen Connolly <st...@gmail.com>

> I have considered changing the default so that if the effective pom
> includes
> an SCM section then it would default to false...
>
> but the problem occurs if the parent has an scm section but we are not in
> scm, e..g. if I use apache-parent-7 as my parent even though I am not in
> apache's svn server then I will have an scm section which is invalid.
>
> Given that v-m-p rewrites pom.xml files, and there is the potential to
> truely screw your build over, it seemed safer to add the default as
> generate
> the backup.
>
> you can always add versions:commit to the end of any command line invoking
> v-m-p and the backup will bre removed...
>
> e.g.
>
> I often set versions like so
>
> mvn versions:set versions:commit -DnewVersion=1.0.4-SNAPSHOT
>
> -Stephen
>
> On 6 December 2010 13:22, Anders Hammar <an...@hammar.net> wrote:
>
> > Well, I guess it was decided at some point as a good default behavior.
> > Changing a default behavior is not good as it will trick people when
> > upgrading.
> > But you can always disable this in the pluginManagement section (via the
> > generateBackupPoms param) of your project.
> >
> >
> http://mojo.codehaus.org/versions-maven-plugin/set-mojo.html#generateBackupPoms
> >
> > /Anders
> >
> > On Mon, Dec 6, 2010 at 13:57, Wim Deblauwe <wi...@gmail.com>
> wrote:
> >
> > > Hi,
> > >
> > > I wonder why the versions-maven-plugin generates backup poms by
> default?
> > I
> > > would assume that 95% of maven users also uses some kind of version
> > control
> > > system, so I really don't see the need for that.
> > >
> > > regards,
> > >
> > > Wim
> > >
> >
>

Re: [versions-maven-plugin] Why is the default to generate backup poms?

Posted by Stephen Connolly <st...@gmail.com>.
I have considered changing the default so that if the effective pom includes
an SCM section then it would default to false...

but the problem occurs if the parent has an scm section but we are not in
scm, e..g. if I use apache-parent-7 as my parent even though I am not in
apache's svn server then I will have an scm section which is invalid.

Given that v-m-p rewrites pom.xml files, and there is the potential to
truely screw your build over, it seemed safer to add the default as generate
the backup.

you can always add versions:commit to the end of any command line invoking
v-m-p and the backup will bre removed...

e.g.

I often set versions like so

mvn versions:set versions:commit -DnewVersion=1.0.4-SNAPSHOT

-Stephen

On 6 December 2010 13:22, Anders Hammar <an...@hammar.net> wrote:

> Well, I guess it was decided at some point as a good default behavior.
> Changing a default behavior is not good as it will trick people when
> upgrading.
> But you can always disable this in the pluginManagement section (via the
> generateBackupPoms param) of your project.
>
> http://mojo.codehaus.org/versions-maven-plugin/set-mojo.html#generateBackupPoms
>
> /Anders
>
> On Mon, Dec 6, 2010 at 13:57, Wim Deblauwe <wi...@gmail.com> wrote:
>
> > Hi,
> >
> > I wonder why the versions-maven-plugin generates backup poms by default?
> I
> > would assume that 95% of maven users also uses some kind of version
> control
> > system, so I really don't see the need for that.
> >
> > regards,
> >
> > Wim
> >
>

Re: [versions-maven-plugin] Why is the default to generate backup poms?

Posted by Anders Hammar <an...@hammar.net>.
Well, I guess it was decided at some point as a good default behavior.
Changing a default behavior is not good as it will trick people when
upgrading.
But you can always disable this in the pluginManagement section (via the
generateBackupPoms param) of your project.
http://mojo.codehaus.org/versions-maven-plugin/set-mojo.html#generateBackupPoms

/Anders

On Mon, Dec 6, 2010 at 13:57, Wim Deblauwe <wi...@gmail.com> wrote:

> Hi,
>
> I wonder why the versions-maven-plugin generates backup poms by default? I
> would assume that 95% of maven users also uses some kind of version control
> system, so I really don't see the need for that.
>
> regards,
>
> Wim
>