From: Rafael Kitover Date: Sun, 9 Sep 2012 16:09:28 +0000 (-0400) Subject: add a loud warning to Makefile.PL about rel attrs X-Git-Tag: 0.07033~1 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=10b0a36e560e0a441674b0b4d247c8d0075925ed;p=dbsrgits%2FDBIx-Class-Schema-Loader.git add a loud warning to Makefile.PL about rel attrs Print a big boxed warning when running Makefile.PL (e.g. when installing via CPAN) about the changes to belongs_to relationship attributes in the last few revisions at the prompting of mst. --- diff --git a/Changes b/Changes index 30af3f6..641aa74 100644 --- a/Changes +++ b/Changes @@ -1,5 +1,10 @@ Revision history for Perl extension DBIx::Class::Schema::Loader + - more thoroughly document the new behavior for relationship attributes + under "relationship_attrs" in ::Base POD + - add a loud WARNING to Makefile.PL about the new behavior for + relationship attributes + 0.07032 2012-09-09 13:17:20 - SQLite: detect is_deferrable for inline FKs - support coderefs for relationship_attrs diff --git a/Makefile.PL b/Makefile.PL index c0a41a4..2b2e4e4 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -60,6 +60,27 @@ requires 'String::ToIdentifier::EN' => '0.05'; requires 'String::CamelCase' => '0.02'; requires 'Hash::Merge' => 0; +print <<"EOF"; +******************* DBIx::Class::Schema::Loader WARNING *********************** +The default attributes for belongs_to relationships for foreign keys with no +rules has been changed for most databases, and is soon changing for the rest, +as ON DELETE/UPDATE and DEFERRABLE clauses for foreign keys are now being +introspected. + +THIS MAY AFFECT YOUR DDL DIFFS WHEN DEPLOYING + +YOUR GENERATED CODE WILL ALMOST CERTAINLY CHANGE + +Read more about the changes in "relationship_attrs" in: + +perldoc DBIx::Class::Schema::Loader::Base + +https://metacpan.org/module/DBIx::Class::Schema::Loader::Base#relationship_attrs + +See also the "Changes" file for the last few revisions. +******************************************************************************* +EOF + if ($Module::Install::AUTHOR && ! $args->{skip_author_deps}) { eval { require Module::Install::ReadmeFromPod } or die "\nYou need Module::Install::ReadmeFromPod installed to run this Makefile.PL in author mode:\n\n$@\n";