Login | Register
My pages Projects Community openCollabNet

Discussions > dev > [Subclipse-dev] Branch with switch customization : little problem

subclipse
Discussion topic

Hide all messages in topic

All messages in topic

RE: [Subclipse-dev] Branch with switch customization : little problem

Author selsemore
Full name Stephen Elsemore
Date 2012-07-11 10:39:31 PDT
Message BranchTagAction runs the BranchTagOperation as a background job, so you can't modify the pom.xml file in BranchTagAction. You would need to do this in the BranchTagOperation itself, just after the SwitchToUrlCommand is run. Also, after you modify the pom.xml file, you will probably need to do a localRefresh on the resource so that Eclipse and Subclipse will be aware of your changes.

> Hello,
>
>
> In my society, we use subclipse to manage our Maven projects in SVN.
> But now a request have been made to automatically adapt the pom.xml
> just after the creation of a branch.
>
> I began to code a new BranchTagAction to customize the way the branch
> are created.
> In this new BranchTagAction, i use the BranchTagOperation without
> modification but i force the switch tho the newly created branch.
>
> But i have a problem because just after the call to
> "branchTagOperation?run()", eclipse does not see the branch switch and so i
> can not modify the pom.xml files. In fact when i began to loop through the
> project in Eclipse, all the project remain on the "trunk" even the one for
> wich a branch have just been created.
>
> As i can see, the switch is really made at the end of the execute
> method of the BranchTagAction.
>
> So my question is : how can i code my action to be sure that the switch
> is well executed before i can begin the modification of my pom.xml ?
>
> The development is on with Eclipse 4.2 and so with Subclipse 1.8.11
>
> If you need more information do not hesitate to ask.
>
> Thank you for your answers.

[Subclipse-dev] Branch with switch customization : little problem

Author Lionel Hubeau <lhubeau at gmail dot com>
Full name Lionel Hubeau <lhubeau at gmail dot com>
Date 2012-07-11 02:01:11 PDT
Message Hello,


     In my society, we use subclipse to manage our Maven projects in SVN.
     But now a request have been made to automatically adapt the pom.xml
just after the creation of a branch.

     I began to code a new BranchTagAction to customize the way the branch
are created.
     In this new BranchTagAction, i use the BranchTagOperation without
modification but i force the switch tho the newly created branch.

    But i have a problem because just after the call to
"branchTagOperation?run()", eclipse does not see the branch switch and so i
can not modify the pom.xml files. In fact when i began to loop through the
project in Eclipse, all the project remain on the "trunk" even the one for
wich a branch have just been created.

    As i can see, the switch is really made at the end of the execute
method of the BranchTagAction.

    So my question is : how can i code my action to be sure that the switch
is well executed before i can begin the modification of my pom.xml ?

     The development is on with Eclipse 4.2 and so with Subclipse 1.8.11

     If you need more information do not hesitate to ask.

Thank you for your answers.
Attachments
Messages per page: