]> wagnertech.de Git - mfinanz.git/blobdiff - scripts/find-use.pl
find-use: Rose::DB::Object::Constants hartcodiert
[mfinanz.git] / scripts / find-use.pl
index 3df14f4591c0833acea67fcca9a44d75a79b9736..320a3690a0b10afeeb2dd939a1b07905fb782097 100755 (executable)
@@ -1,4 +1,13 @@
 #!/usr/bin/perl -l
 #!/usr/bin/perl -l
+
+BEGIN {
+  use FindBin;
+
+  unshift(@INC, $FindBin::Bin . '/../modules/override'); # Use our own versions of various modules (e.g. YAML).
+  push   (@INC, $FindBin::Bin . '/..');                  # '.' will be removed from @INC soon.
+  push   (@INC, $FindBin::Bin . '/../modules/fallback'); # Only use our own versions of modules if there's no system version.
+}
+
 use strict;
 #use warnings; # corelist and find throw tons of warnings
 use File::Find;
 use strict;
 #use warnings; # corelist and find throw tons of warnings
 use File::Find;
@@ -23,6 +32,7 @@ my (%uselines, %modules, %supplied, %requires);
    'Rose::DB::Object::Metadata'          => 1,
    'Rose::DB::Object::Helpers'           => 1,
    'Rose::DB::Object::Util'              => 1,
    'Rose::DB::Object::Metadata'          => 1,
    'Rose::DB::Object::Helpers'           => 1,
    'Rose::DB::Object::Util'              => 1,
+   'Rose::DB::Object::Constants'         => 1,
   },
   'Rose::Object' => {
     'Rose::Object::MakeMethods::Generic' => 1,
   },
   'Rose::Object' => {
     'Rose::Object::MakeMethods::Generic' => 1,
@@ -55,6 +65,8 @@ GetOptions(
   'files-with-match|l' => \ my $l,
 );
 
   'files-with-match|l' => \ my $l,
 );
 
+chmod($FindBin::Bin . '/..');
+
 find(sub {
   return unless /(\.p[lm]|console)$/;
 
 find(sub {
   return unless /(\.p[lm]|console)$/;