You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Erwin van der Koogh <vd...@apache.org> on 2004/11/17 11:44:04 UTC

patch for new CVS dateformat (MPCHANGELOG-48)

Hallo all,

Recently the CVS guys, in their infinite wisdom, decided to change the date 
format in their log messages to ISO8601 format. This has broken the 
changelog plugin.

I have posted the patch on the jira issue, but thought it might be easy to 
send it here as well and explain it a bit.

ChangeLogEntry:

Taken out CVS date parsing and only have a setDate(Date) and getDate(). 
This is what all other SCM systems use and it makes it more consistent and 
less error-prone.

CvsChangeLogParser:

I created a new method parseDate that tries to parse the date with both 
formats. I also slightly changed the way the sentence is parsed. It used to 
be parses by word, but now I parsed it by field (seperated by ;) and then 
take off the label.

ChangeLogEntryTest:
Took out the StringDate stuff as it's no longer needed and had to make 
other tiny adjustments.

CvsChangeLostParserTest:
Added a testcase for the new dateformat. I have added a parse method that's 
called twice with both files.

I have also included the testfile, this should go next to cvslog.txt and be 
called cvslog_new.txt

The legal side is covered as well, I am an Apache committer on the 
xml-security stuff and CLAs and stuff are all in place.

If there are any questions, please let me know, but please email me 
personally as I might not read the list as closely, certainly not in the 
future.

Erwin