--- a/Makefile.PL +++ a/Makefile.PL @@ -693,7 +693,6 @@ $config{'BIB_RETRIEVAL_CFG'} = 'retrieval-info-bib-dom.xml'; if ($config{'INSTALL_MODE'} ne "dev") { push @{ $pl_files->{'rewrite-config.PL'} }, ( 'blib/PERL_MODULE_DIR/C4/Context.pm', - 'blib/SCRIPT_NONDEV_DIR/kohalib.pl' ); } --- a/misc/add_date_fields_to_marc_records.pl +++ a/misc/add_date_fields_to_marc_records.pl @@ -17,11 +17,6 @@ use Modern::Perl; -BEGIN { - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Koha::Script; use Getopt::Long qw( GetOptions ); --- a/misc/batchCompareMARCvsFrameworks.pl +++ a/misc/batchCompareMARCvsFrameworks.pl @@ -4,12 +4,6 @@ use strict; #use warnings; FIXME - Bug 2505 -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/kohalib.pl" }; -} # Koha modules used use Koha::Script; --- a/misc/batchDeleteUnusedSubfields.pl +++ a/misc/batchDeleteUnusedSubfields.pl @@ -3,12 +3,6 @@ use strict; #use warnings; FIXME - Bug 2505 -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/kohalib.pl" }; -} # Koha modules used use Koha::Script; --- a/misc/batchImportMARCWithBiblionumbers.pl +++ a/misc/batchImportMARCWithBiblionumbers.pl @@ -3,12 +3,6 @@ # Written by TG on 10/04/2006 use strict; #use warnings; FIXME - Bug 2505 -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/kohalib.pl" }; -} # Koha modules used --- a/misc/batchRebuildBiblioTables.pl +++ a/misc/batchRebuildBiblioTables.pl @@ -5,13 +5,6 @@ use strict; #use warnings; FIXME - Bug 2505 -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/kohalib.pl" }; -} - # Koha modules used use Koha::Script; use MARC::Record; --- a/misc/batchRepairMissingBiblionumbers.pl +++ a/misc/batchRepairMissingBiblionumbers.pl @@ -4,12 +4,6 @@ # Revised by Joshua Ferraro on 03/31/2006 use strict; use warnings; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/kohalib.pl" }; -} # Koha modules used use Koha::Script; --- a/misc/commit_file.pl +++ a/misc/commit_file.pl @@ -2,12 +2,6 @@ use strict; use warnings; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/kohalib.pl" }; -} use Koha::Script; use C4::Context; --- a/misc/cronjobs/advance_notices.pl +++ a/misc/cronjobs/advance_notices.pl @@ -40,12 +40,6 @@ use strict; use warnings; use Getopt::Long qw( GetOptions ); use Pod::Usage qw( pod2usage ); -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} use Koha::Script -cron; use C4::Context; use C4::Letters; --- a/misc/cronjobs/batch_anonymise.pl +++ a/misc/cronjobs/batch_anonymise.pl @@ -20,14 +20,6 @@ use strict; use warnings; -BEGIN { - - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Koha::Script -cron; use C4::Context; use Koha::Patrons; --- a/misc/cronjobs/build_browser_and_cloud.pl +++ a/misc/cronjobs/build_browser_and_cloud.pl @@ -3,12 +3,6 @@ use strict; #use warnings; FIXME - Bug 2505 -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; -} use Koha::Script -cron; use C4::Koha; --- a/misc/cronjobs/cart_to_shelf.pl +++ a/misc/cronjobs/cart_to_shelf.pl @@ -32,13 +32,6 @@ use Koha::Script -cron; use C4::Items qw( CartToShelf ); use C4::Log qw( cronlogaction ); -BEGIN { - - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} use C4::Context; use Getopt::Long qw( GetOptions ); --- a/misc/cronjobs/cleanup_database.pl +++ a/misc/cronjobs/cleanup_database.pl @@ -28,13 +28,6 @@ use constant DEFAULT_SEARCHHISTORY_PURGEDAYS => 30; use constant DEFAULT_SHARE_INVITATION_EXPIRY_DAYS => 14; use constant DEFAULT_DEBARMENTS_PURGEDAYS => 30; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Koha::Script -cron; use C4::Context; use C4::Search; --- a/misc/cronjobs/delete_records_via_leader.pl +++ a/misc/cronjobs/delete_records_via_leader.pl @@ -23,14 +23,6 @@ use Modern::Perl; binmode( STDOUT, ":encoding(UTF-8)" ); -BEGIN { - - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Getopt::Long qw( GetOptions ); use Pod::Usage qw( pod2usage ); use Koha::Script -cron; --- a/misc/cronjobs/gather_print_notices.pl +++ a/misc/cronjobs/gather_print_notices.pl @@ -2,13 +2,6 @@ use Modern::Perl; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use CGI; # NOT a CGI script, this is just to keep C4::Templates::gettemplate happy use Koha::Script -cron; use C4::Context; --- a/misc/cronjobs/holds/auto_unsuspend_holds.pl +++ a/misc/cronjobs/holds/auto_unsuspend_holds.pl @@ -20,13 +20,6 @@ use strict; use warnings; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - # cancel all expired hold requests use Koha::Script -cron; --- a/misc/cronjobs/holds/build_holds_queue.pl +++ a/misc/cronjobs/holds/build_holds_queue.pl @@ -8,12 +8,6 @@ use strict; use warnings; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} use Koha::Script -cron; use C4::HoldsQueue qw(CreateQueue); --- a/misc/cronjobs/holds/cancel_expired_holds.pl +++ a/misc/cronjobs/holds/cancel_expired_holds.pl @@ -42,13 +42,6 @@ use Modern::Perl; use Getopt::Long qw( GetOptions ); use Pod::Usage qw( pod2usage ); -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Koha::Script -cron; use C4::Reserves; use C4::Log qw( cronlogaction ); --- a/misc/cronjobs/holds/cancel_unfilled_holds.pl +++ a/misc/cronjobs/holds/cancel_unfilled_holds.pl @@ -18,13 +18,6 @@ use Modern::Perl; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Getopt::Long qw( GetOptions ); use Pod::Usage qw( pod2usage ); --- a/misc/cronjobs/holds/holds_reminder.pl +++ a/misc/cronjobs/holds/holds_reminder.pl @@ -17,14 +17,6 @@ use Modern::Perl; -BEGIN { - - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Getopt::Long qw( GetOptions ); use Pod::Usage qw( pod2usage ); use DateTime; --- a/misc/cronjobs/import_webservice_batch.pl +++ a/misc/cronjobs/import_webservice_batch.pl @@ -21,14 +21,6 @@ use strict; use warnings; use utf8; -BEGIN { - - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Getopt::Long qw( GetOptions ); use Koha::Script -cron; use C4::ImportBatch qw( BatchCommitRecords ); --- a/misc/cronjobs/longoverdue.pl +++ a/misc/cronjobs/longoverdue.pl @@ -27,12 +27,6 @@ longoverdue.pl cron script to set lost statuses on overdue materials. use strict; use warnings; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} use Getopt::Long qw( GetOptions ); use Pod::Usage qw( pod2usage ); --- a/misc/cronjobs/membership_expiry.pl +++ a/misc/cronjobs/membership_expiry.pl @@ -139,12 +139,6 @@ any field from the branches table use Modern::Perl; use Getopt::Long qw( GetOptions ); use Pod::Usage qw( pod2usage ); -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} use Koha::Script -cron; use C4::Context; --- a/misc/cronjobs/overdue_notices.pl +++ a/misc/cronjobs/overdue_notices.pl @@ -20,14 +20,6 @@ use Modern::Perl; -BEGIN { - - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Getopt::Long qw( GetOptions ); use Pod::Usage qw( pod2usage ); use Text::CSV_XS; --- a/misc/cronjobs/patron_emailer.pl +++ a/misc/cronjobs/patron_emailer.pl @@ -18,13 +18,6 @@ use Modern::Perl; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Koha::Script -cron; use Getopt::Long qw( GetOptions ); use Pod::Usage qw( pod2usage ); --- a/misc/cronjobs/process_message_queue.pl +++ a/misc/cronjobs/process_message_queue.pl @@ -19,12 +19,6 @@ use strict; use warnings; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} use Koha::Script -cron; use C4::Letters qw( SendQueuedMessages ); --- a/misc/cronjobs/purge_suggestions.pl +++ a/misc/cronjobs/purge_suggestions.pl @@ -19,13 +19,6 @@ use Modern::Perl; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Getopt::Long qw( GetOptions ); use Koha::Script -cron; --- a/misc/cronjobs/reconcile_balances.pl +++ a/misc/cronjobs/reconcile_balances.pl @@ -55,13 +55,6 @@ use Getopt::Long qw( GetOptions ); use Pod::Usage qw( pod2usage ); use Try::Tiny qw( catch try ); -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Koha::Script -cron; use C4::Log qw( cronlogaction ); --- a/misc/cronjobs/runreport.pl +++ a/misc/cronjobs/runreport.pl @@ -38,13 +38,6 @@ use Encode qw( decode ); use JSON qw( to_json ); use Try::Tiny qw( catch try ); -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - =head1 NAME runreport.pl - Run pre-existing saved reports --- a/misc/cronjobs/serialsUpdate.pl +++ a/misc/cronjobs/serialsUpdate.pl @@ -20,14 +20,6 @@ use strict; use warnings; -BEGIN { - - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Koha::Script -cron; use C4::Context; use C4::Serials qw( GetSubscription GetNextDate ModSerialStatus ); --- a/misc/cronjobs/staticfines.pl +++ a/misc/cronjobs/staticfines.pl @@ -27,14 +27,6 @@ use Modern::Perl; -BEGIN { - - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/kohalib.pl" }; -} - use Date::Calc qw( Date_to_Days ); use Koha::Script -cron; --- a/misc/cronjobs/thirdparty/TalkingTech_itiva_inbound.pl +++ a/misc/cronjobs/thirdparty/TalkingTech_itiva_inbound.pl @@ -20,14 +20,6 @@ use strict; use warnings; -BEGIN { - - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Getopt::Long qw( GetOptions ); use Pod::Usage qw( pod2usage ); --- a/misc/cronjobs/thirdparty/TalkingTech_itiva_outbound.pl +++ a/misc/cronjobs/thirdparty/TalkingTech_itiva_outbound.pl @@ -20,14 +20,6 @@ use strict; use warnings; -BEGIN { - - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Getopt::Long qw( GetOptions ); use Pod::Usage qw( pod2usage ); --- a/misc/cronjobs/update_patrons_category.pl +++ a/misc/cronjobs/update_patrons_category.pl @@ -17,13 +17,6 @@ use Modern::Perl; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use C4::Context; use Getopt::Long qw( GetOptions ); use Pod::Usage qw( pod2usage ); --- a/misc/cronjobs/update_totalissues.pl +++ a/misc/cronjobs/update_totalissues.pl @@ -20,14 +20,6 @@ use strict; use warnings; -BEGIN { - - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Getopt::Long qw( GetOptions ); use Pod::Usage qw( pod2usage ); --- a/misc/exportauth.pl +++ a/misc/exportauth.pl @@ -5,12 +5,6 @@ use strict; #use warnings; FIXME - Bug 2505 -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/kohalib.pl" }; -} use Koha::Script; use C4::Context; --- a/misc/kohalib.pl +++ a/misc/kohalib.pl @@ -1,52 +0,0 @@ -#!/usr/bin/perl - -# Copyright (C) 2007 LibLime -# -# This file is part of Koha. -# -# Koha is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 3 of the License, or -# (at your option) any later version. -# -# Koha is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with Koha; if not, see . - -# This script is used by command-line utilities to set -# @INC properly -- specifically, to point to the directory -# containing the installed version of the C4 modules. -# -# This depends on the installer replacing the \_\_PERL_MODULE_DIR\_\_ -# string with the path to the Koha modules directory. This is done -# only during a 'standard' or 'single' mode installation. If Koha -# is being run from a git checkout (and thus installed in 'dev' mode), -# this is a no-op. -# -# To use this script, a command-line utility should do the following before -# 'use'ing any C4 modules. -# -# BEGIN { -# use FindBin; -# eval { require "$FindBin::Bin/kohalib.pl" }; -# # adjust path to point to kohalib.pl relative -# # to location of script -# } -# - -use strict; -#use warnings; FIXME - Bug 2505 - -my $module_dir; -BEGIN { - $module_dir = '__PERL_MODULE_DIR__'; - die if $module_dir =~ /^[_]{2}PERL_MODULE_DIR[_]{2}$/; -} - -use lib $module_dir; - -1; --- a/misc/link_bibs_to_authorities.pl +++ a/misc/link_bibs_to_authorities.pl @@ -3,14 +3,6 @@ use strict; use warnings; -BEGIN { - - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/kohalib.pl" }; -} - use Koha::Script; use C4::Context; use C4::Biblio qw( --- a/misc/load_testing/benchmark_circulation.pl +++ a/misc/load_testing/benchmark_circulation.pl @@ -4,12 +4,6 @@ use strict; use warnings; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/kohalib.pl" }; -} use HTTPD::Bench::ApacheBench; use LWP::UserAgent; --- a/misc/load_testing/benchmark_staff.pl +++ a/misc/load_testing/benchmark_staff.pl @@ -4,12 +4,6 @@ use strict; use warnings; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/kohalib.pl" }; -} use Getopt::Long qw( GetOptions ); use HTTPD::Bench::ApacheBench; --- a/misc/maintenance/UNIMARC_fix_collectiontitle.pl +++ a/misc/maintenance/UNIMARC_fix_collectiontitle.pl @@ -7,11 +7,6 @@ use strict; use warnings; -BEGIN { - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Koha::Script; sub process { --- a/misc/maintenance/UNIMARC_sync_date_created_with_marc_biblio.pl +++ a/misc/maintenance/UNIMARC_sync_date_created_with_marc_biblio.pl @@ -7,11 +7,6 @@ use strict; use warnings; -BEGIN { - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Koha::Script; use C4::Biblio qw( GetMarcBiblio ModBiblio ); use Getopt::Long qw( GetOptions ); --- a/misc/maintenance/borrowers-force-messaging-defaults.pl +++ a/misc/maintenance/borrowers-force-messaging-defaults.pl @@ -19,12 +19,6 @@ use strict; use warnings; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} use Koha::Script; use C4::Context; --- a/misc/maintenance/fix_accountlines_date.pl +++ a/misc/maintenance/fix_accountlines_date.pl @@ -19,12 +19,6 @@ use strict; use warnings; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} use Koha::Script; use C4::Context; --- a/misc/maintenance/fix_accountlines_rmdupfines_bug8253.pl +++ a/misc/maintenance/fix_accountlines_rmdupfines_bug8253.pl @@ -20,13 +20,6 @@ use strict; use warnings; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Koha::Script; use C4::Context; --- a/misc/maintenance/fix_mysql_constraints.pl +++ a/misc/maintenance/fix_mysql_constraints.pl @@ -18,13 +18,6 @@ # along with Koha; if not, see . use Modern::Perl; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - my $lib = "$FindBin::Bin/../kohalib.pl"; - eval { require $lib }; -} use Getopt::Long qw( GetOptions ); use Pod::Usage qw( pod2usage ); --- a/misc/maintenance/touch_all_biblios.pl +++ a/misc/maintenance/touch_all_biblios.pl @@ -19,12 +19,6 @@ use strict; use warnings; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} # possible modules to use use Getopt::Long qw( GetOptions ); --- a/misc/maintenance/touch_all_items.pl +++ a/misc/maintenance/touch_all_items.pl @@ -19,12 +19,6 @@ use strict; use warnings; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} # possible modules to use use Getopt::Long qw( GetOptions ); --- a/misc/migration_tools/22_to_30/convert_to_utf8.pl +++ a/misc/migration_tools/22_to_30/convert_to_utf8.pl @@ -5,14 +5,6 @@ use strict; use warnings; -BEGIN { - - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../../kohalib.pl" }; -} - use C4::Context; my $dbh = C4::Context->dbh(); my $sth = $dbh->prepare("Show tables"); --- a/misc/migration_tools/22_to_30/export_Authorities.pl +++ a/misc/migration_tools/22_to_30/export_Authorities.pl @@ -1,11 +1,5 @@ #!/usr/bin/perl use Modern::Perl; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../../kohalib.pl" }; -} use C4::Context; #use MARC::File::XML(BinaryEncoding=>"utf8"); #use MARC::File::USMARC; --- a/misc/migration_tools/22_to_30/export_Authorities_xml.pl +++ a/misc/migration_tools/22_to_30/export_Authorities_xml.pl @@ -1,11 +1,5 @@ #!/usr/bin/perl use Modern::Perl; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../../kohalib.pl" }; -} use C4::Context; use MARC::File::XML(BinaryEncoding=>"utf8"); use C4::AuthoritiesMarc; --- a/misc/migration_tools/22_to_30/missing090field.pl +++ a/misc/migration_tools/22_to_30/missing090field.pl @@ -4,12 +4,6 @@ # Revised by Joshua Ferraro on 03/31/2006 use strict; #use warnings; FIXME - Bug 2505 -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../../kohalib.pl" }; -} # Koha modules used --- a/misc/migration_tools/22_to_30/move_marc_to_authheader.pl +++ a/misc/migration_tools/22_to_30/move_marc_to_authheader.pl @@ -4,12 +4,6 @@ # scraped from updatedatabase for dev week by chris@katipo.co.nz use strict; #use warnings; FIXME - Bug 2505 -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../../kohalib.pl" }; -} use C4::Context; use C4::AuthoritiesMarc; use MARC::Record; --- a/misc/migration_tools/22_to_30/move_marc_to_biblioitems.pl +++ a/misc/migration_tools/22_to_30/move_marc_to_biblioitems.pl @@ -2,12 +2,6 @@ use Modern::Perl; # script to shift marc to biblioitems # scraped from updatedatabase for dev week by chris@katipo.co.nz -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../../kohalib.pl" }; -} use C4::Context; use MARC::Record; use MARC::File::XML ( BinaryEncoding => 'utf8' ); --- a/misc/migration_tools/22_to_30/rebuild_leader.pl +++ a/misc/migration_tools/22_to_30/rebuild_leader.pl @@ -4,12 +4,6 @@ # Revised by Joshua Ferraro on 03/31/2006 use strict; #use warnings; FIXME - Bug 2505 -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../../kohalib.pl" }; -} # Koha modules used --- a/misc/migration_tools/22_to_30/rebuild_unimarc_100.pl +++ a/misc/migration_tools/22_to_30/rebuild_unimarc_100.pl @@ -4,12 +4,6 @@ # Revised by Joshua Ferraro on 03/31/2006 use strict; #use warnings; FIXME - Bug 2505 -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../../kohalib.pl" }; -} # Koha modules used --- a/misc/migration_tools/bulkmarcimport.pl +++ a/misc/migration_tools/bulkmarcimport.pl @@ -3,12 +3,6 @@ use Modern::Perl; #use diagnostics; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} # Koha modules used use MARC::File::USMARC; --- a/misc/migration_tools/checkNonIndexedBiblios.pl +++ a/misc/migration_tools/checkNonIndexedBiblios.pl @@ -23,14 +23,6 @@ use strict; -BEGIN { - - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/kohalib.pl" }; -} - # Koha modules used use Koha::Script; use C4::Context; --- a/misc/migration_tools/create_analytical_rel.pl +++ a/misc/migration_tools/create_analytical_rel.pl @@ -2,12 +2,6 @@ use strict; #use warnings; FIXME - Bug 2505 -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} use Koha::Script; use C4::Context; --- a/misc/migration_tools/import_lexile.pl +++ a/misc/migration_tools/import_lexile.pl @@ -41,14 +41,6 @@ use Koha::Database; binmode STDOUT, ':encoding(UTF-8)'; -BEGIN { - - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - my $help; my $confirm; my $test; --- a/misc/migration_tools/switch_marc21_series_info.pl +++ a/misc/migration_tools/switch_marc21_series_info.pl @@ -22,13 +22,6 @@ use warnings; # Script to switch the MARC21 440$anv and 490$av information -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/../kohalib.pl" }; -} - use Koha::Script; use C4::Biblio qw( GetFrameworkCode GetMarcBiblio ModBiblioMarc ); use C4::Context; --- a/misc/stage_file.pl +++ a/misc/stage_file.pl @@ -20,12 +20,6 @@ # along with Koha; if not, see . use Modern::Perl; -BEGIN { - # find Koha's Perl modules - # test carefully before changing this - use FindBin (); - eval { require "$FindBin::Bin/kohalib.pl" }; -} use Koha::Script; use C4::Context; --- a/t/db_dependent/00-strict.t +++ a/t/db_dependent/00-strict.t @@ -35,7 +35,6 @@ my @dirs = ( ); $Test::Strict::TEST_STRICT = 0; -$Test::Strict::TEST_SKIP = [ 'misc/kohalib.pl' ]; my $ncpu; if ( $ENV{KOHA_PROVE_CPUS} ) { --- a/xt/yaml_valid.t +++ a/xt/yaml_valid.t @@ -23,11 +23,6 @@ use File::Find; use Test::More; -BEGIN { - use FindBin; - eval { require "$FindBin::Bin/../misc/kohalib.pl" }; -} - my $filebase = "$FindBin::Bin/../koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences"; my @files; --