Wednesday, April 15, 2009

Use the Pre-Session extended rule for a change log

Always keep a change log. We do that in C++ and Java, so why not do it here. Open up any map that I wrote that look at the pre-session rule and you'll see all the change history going back to its original creation.

I always create a comment block like this:

// -------------------------------------------------------------------------
// File: Partner_004010_850_inbound.map
//
// History:
// 2009-04-15 abaird Add default country code rule
// - Back end requires a specific country code, but partners often omit
// the N404 element. Add a rule to default US or CA for N404 if N402
// contains a valid state or province code.
//
// 2008-11-09 abaird Original version
// -------------------------------------------------------------------------
If the change calls for a reference from a defect management tool or a feature, then you should include it here.

It is the literal text of this entry that I always paste into the Perforce changelist comments.

Every time you check out the map to make some changes, always write a few lines here to give a summary of what you changed.

Comments here are saved only in the source file and not compiled into the runtime at all, and therefore have no performance impact whatsoever. This is therefore an excellent way to maintain some change documentation.

No comments:

Post a Comment