diff --git a/README b/README index 2c4d6cb..9b0935f 100644 --- a/README +++ b/README @@ -35,7 +35,7 @@ You can also look for information at: http://search.cpan.org/dist/Module-Install-DiffCheck Version control - http://github.com/jhannah/module-install-schemacheck + http://github.com/jhannah/module-install-diffcheck COPYRIGHT AND LICENCE diff --git a/lib/Module/Install/DiffCheck.pm b/lib/Module/Install/DiffCheck.pm index ae72278..ea3b367 100644 --- a/lib/Module/Install/DiffCheck.pm +++ b/lib/Module/Install/DiffCheck.pm @@ -2,7 +2,7 @@ package Module::Install::DiffCheck; =head1 NAME -Module::Install::DiffCheck - Run diff commands for potential trouble +Module::Install::DiffCheck - Run diff commands looking for deployment problems =head1 SYNOPSIS @@ -39,7 +39,7 @@ Our software development lifecycle revolves around SVN "tags" (actually branches For any given tag, new tables may have been introduced, tables may have been altered, or old tables may have been removed. We needed a quick way to make sure that every time we deploy a tag, the relevant database schema(s) are already in -place. schemacheck() lists all errors and dies if it detects problems. +place. diffcheck() lists all errors and dies if it detects problems. We use both L C and C to store our schemas to disk. (Either one is fine. I'm not sure why we do both.) @@ -100,12 +100,12 @@ sub diffcheck { *** Module::Install::DiffCheck EOF - unless ($args{diff_cmd}) { - die "schemacheck() requires a diff_cmd argument"; + unless ($args{diff_commands}) { + die "diffcheck() requires a diff_commands argument"; } my $fatal = 0; - if ($args{refresher}) { + if ($args{before_diff_commands}) { $fatal += $self->_run_before_diff_commands(\%args); } $fatal += $self->_run_diff_commands(\%args); @@ -144,6 +144,7 @@ sub _run_before_diff_commands { sub _run_diff_commands { my ($self, $args) = @_; + my $fatal = 0; foreach my $cmd (@{$args->{diff_commands}}) { print "running '$cmd'\n"; my $diff = `$cmd`; @@ -154,7 +155,6 @@ sub _run_diff_commands { # Verbose => 1, ); - my $fatal = 0; foreach my $change ( $parser->changes ) { next unless ($change->type); # How do blanks get in here? my $msg = sprintf( @@ -201,7 +201,7 @@ L That bug stops C diffs from being processed currectly. So, for now I'm only using this against L schemas. -Please report any bugs or feature requests to C, or through +Please report any bugs or feature requests to C, or through the web interface at L. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes. @@ -233,7 +233,7 @@ L =item * Version control -L, +L, L =back