#!/usr/bin/perl
#
# This little routine build a table of all the ClearCase elements that the
# user has checked out. 
#
# For development purposes, we print dump the table.
#

open(P,"cleartool lsc -avobs -me |")
	|| die "Can't run \"cleartool lsc -avobs -me\"\n";

for (<P>) {
	if (/version\s+"(.*)"\s+from\s+(.*)/) {
		$checkedout{$1} = $2;
	}
}
for $k (sort keys %checkedout) {
	$v = $checkedout{$k};
	print "$k\t$v\n";
}

exit 0;
