You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by Antonio Petrelli <br...@tariffenet.it> on 2006/08/28 10:49:17 UTC

[OT] Re: Patch all or individual commits?

Martin Cooper ha scritto:
> Please try to check in all of the files for a particular issue in a 
> single
> commit.

Funny how things changed since the use of CVS. I don't remember where I 
read it, but someone wrote that it is better to commit a single file at 
a time, so it is clear what it is changed in that file and why it has 
been done. Notice that I agree with both Martin and Wendy :-)
As I see it, things in IT go back and forth, for instance the recent 
re-consideration of Model 1 webapp structure, lovers and haters of XML, 
to strong-type or not-to-strong-type, etc.
Where is The Truth? :-P

Ciao
Antonio

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: [OT] Re: Patch all or individual commits?

Posted by Paul Speed <ps...@progeeks.com>.

Antonio Petrelli wrote:

> Ted Husted ha scritto:
> 
>> Something that could go wrong under CVS is that one file's commit
>> would fail, the others would succeed, and the repository would be in
>> an unexpected state.
> 
> 
> Thank you, I didn't know this CVS problem (maybe because I am too much 
> lucky :-) )
> Now I understand why so much people is migrating from CVS to SVN.
> 
> Ciao
> Antonio

Well, and it may only be accepted (but partially incorrect) lore at this 
point.  It all depends on why the commit fails.  If it fails for any 
normal reason then CVS should do the right thing.  At my day job we have 
validation scripts for commits that can reject a file and we routinely 
do commits across multiple directories, etc..  We've never had an 
inconsistent commit from this.

But the lore came from somewhere so your mileage may vary I guess.
-Paul

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: [OT] Re: Patch all or individual commits?

Posted by Antonio Petrelli <br...@tariffenet.it>.
Ted Husted ha scritto:
> Something that could go wrong under CVS is that one file's commit
> would fail, the others would succeed, and the repository would be in
> an unexpected state.

Thank you, I didn't know this CVS problem (maybe because I am too much 
lucky :-) )
Now I understand why so much people is migrating from CVS to SVN.

Ciao
Antonio

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: [OT] Re: Patch all or individual commits?

Posted by Ted Husted <hu...@apache.org>.
On 8/28/06, Antonio Petrelli <br...@tariffenet.it> wrote:
> Where is The Truth? :-P

In the implementation. :)

Something that could go wrong under CVS is that one file's commit
would fail, the others would succeed, and the repository would be in
an unexpected state. Smaller commits could be better, since it meant
there was less that could go wrong. SVN uses atomic committs, so
larger, multifile commits are not risky. It all succeeds, or it all
fails.

Under SVN, it's easy to roll things back to a particular commit, and
to reference the changes by the revision number. So if we are
implementing change XYZ, it's helpful to be able to say the change was
implemented in r1234567. And if we decde to roll back, we have an
implicit tag corresponding to the change.

Under CVS, I don't think I ever actually "rolled back" a commit. It
was too much work. Of I needed to undo something, I copy-and-pasted
the code forward. Under SVN, I often rolled back commits that didn't
work, by using SVN to copy forward the files that I want. (Not so much
here, but at work.)

Though, in either case, if the changes to the files are coupled, and
we aren't talking about a humungous number of CVS files, I'd commit
the changes together, for the same reason: "so it is clear what it is
changed in that file and why it has been done."

The evil practice is committing unrelated changes together, or mixing
stylistic and functional changes in the same commit.

-Ted.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org