X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=maint%2Fgen_pod_inherit;h=db0f65a7a97d8eada9663cc4d5dc44d52224e16d;hb=fcf32d045;hp=b7adc1425938eb435c11e26a13d5f2e0575a0a83;hpb=3d4c5a8439e2c5f6b74e6c8f52117ececd9e20fa;p=dbsrgits%2FDBIx-Class.git diff --git a/maint/gen_pod_inherit b/maint/gen_pod_inherit index b7adc14..db0f65a 100755 --- a/maint/gen_pod_inherit +++ b/maint/gen_pod_inherit @@ -4,16 +4,30 @@ use warnings; use strict; my $lib_dir = 'lib'; -my $pod_dir = '.generated_pod'; +my $pod_dir = 'maint/.Generated_Pod'; + +my $result_metapod_fn = "$lib_dir/DBIx/Class/Manual/ResultClass.pod"; die "POD generator must be executed from the dist root\n" unless -d $lib_dir and -d $pod_dir; +require File::Copy; +File::Copy::copy( + "$result_metapod_fn.proto", + "$result_metapod_fn", +) or die "Copying ResultClass proto pod ($result_metapod_fn) failed: $!"; + +# cleanup +END { + local ($@, $!, $?); + unlink $result_metapod_fn; +} + require Pod::Inherit; Pod::Inherit->new({ input_files => $lib_dir, - out_dir => $pod_dir, + out_dir => "$pod_dir/lib", force_permissions => 1, class_map => { "DBIx::Class::Relationship::HasMany" => "DBIx::Class::Relationship",