Bugzilla – Attachment 128063 Details for
Bug 28617
misc/kohalib.pl no longer useful
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 28617: Remove kohalib.pl and rely on PERL5LIB
Bug-28617-Remove-kohalibpl-and-rely-on-PERL5LIB.patch (text/plain), 37.81 KB, created by
Martin Renvoize (ashimema)
on 2021-11-29 10:32:47 UTC
(
hide
)
Description:
Bug 28617: Remove kohalib.pl and rely on PERL5LIB
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2021-11-29 10:32:47 UTC
Size:
37.81 KB
patch
obsolete
>From b9f822989e45d29f07c17091fa539f1fedf12301 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Mon, 19 Jul 2021 11:00:52 +0200 >Subject: [PATCH] Bug 28617: Remove kohalib.pl and rely on PERL5LIB > >The purpose of this script was to load the relevant Koha lib for the >different scripts (installation, cronjob, CLI, etc.) >However it is not used consistently and we prefer to rely on PERL5LIB. > >From bug 28617 comment 6 from Galen: >""" >Time marches on, and one of the motivations for having kohalib.pl - making >it possible to install Koha without setting a single environment variable - >has been obviated by the vast improvements in the ease of installing Koha. > >Consequently, I think kohalib.pl can go away. >""" > >Test plan: >confirm that the changes make sense and that kohalib.pl can be removed >safely. > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> >--- > Makefile.PL | 1 - > misc/add_date_fields_to_marc_records.pl | 5 -- > misc/batchCompareMARCvsFrameworks.pl | 6 --- > misc/batchDeleteUnusedSubfields.pl | 6 --- > misc/batchImportMARCWithBiblionumbers.pl | 6 --- > misc/batchRebuildBiblioTables.pl | 7 --- > misc/batchRepairMissingBiblionumbers.pl | 6 --- > misc/commit_file.pl | 6 --- > misc/cronjobs/advance_notices.pl | 6 --- > misc/cronjobs/batch_anonymise.pl | 8 --- > misc/cronjobs/build_browser_and_cloud.pl | 6 --- > misc/cronjobs/cart_to_shelf.pl | 7 --- > misc/cronjobs/cleanup_database.pl | 7 --- > misc/cronjobs/delete_records_via_leader.pl | 8 --- > misc/cronjobs/gather_print_notices.pl | 7 --- > misc/cronjobs/holds/auto_unsuspend_holds.pl | 7 --- > misc/cronjobs/holds/build_holds_queue.pl | 6 --- > misc/cronjobs/holds/cancel_expired_holds.pl | 7 --- > misc/cronjobs/holds/cancel_unfilled_holds.pl | 7 --- > misc/cronjobs/holds/holds_reminder.pl | 8 --- > misc/cronjobs/import_webservice_batch.pl | 8 --- > misc/cronjobs/longoverdue.pl | 6 --- > misc/cronjobs/membership_expiry.pl | 6 --- > misc/cronjobs/overdue_notices.pl | 8 --- > misc/cronjobs/patron_emailer.pl | 7 --- > misc/cronjobs/process_message_queue.pl | 6 --- > misc/cronjobs/purge_suggestions.pl | 7 --- > misc/cronjobs/reconcile_balances.pl | 7 --- > misc/cronjobs/runreport.pl | 7 --- > misc/cronjobs/serialsUpdate.pl | 8 --- > misc/cronjobs/staticfines.pl | 8 --- > .../thirdparty/TalkingTech_itiva_inbound.pl | 8 --- > .../thirdparty/TalkingTech_itiva_outbound.pl | 8 --- > misc/cronjobs/update_patrons_category.pl | 7 --- > misc/cronjobs/update_totalissues.pl | 8 --- > misc/exportauth.pl | 6 --- > misc/kohalib.pl | 52 ------------------- > misc/link_bibs_to_authorities.pl | 8 --- > misc/load_testing/benchmark_circulation.pl | 6 --- > misc/load_testing/benchmark_staff.pl | 6 --- > .../UNIMARC_fix_collectiontitle.pl | 5 -- > ...MARC_sync_date_created_with_marc_biblio.pl | 5 -- > .../borrowers-force-messaging-defaults.pl | 6 --- > misc/maintenance/fix_accountlines_date.pl | 6 --- > .../fix_accountlines_rmdupfines_bug8253.pl | 7 --- > misc/maintenance/fix_mysql_constraints.pl | 7 --- > misc/maintenance/touch_all_biblios.pl | 6 --- > misc/maintenance/touch_all_items.pl | 6 --- > .../22_to_30/convert_to_utf8.pl | 8 --- > .../22_to_30/export_Authorities.pl | 6 --- > .../22_to_30/export_Authorities_xml.pl | 6 --- > .../22_to_30/missing090field.pl | 6 --- > .../22_to_30/move_marc_to_authheader.pl | 6 --- > .../22_to_30/move_marc_to_biblioitems.pl | 6 --- > .../22_to_30/rebuild_leader.pl | 6 --- > .../22_to_30/rebuild_unimarc_100.pl | 6 --- > misc/migration_tools/bulkmarcimport.pl | 6 --- > .../migration_tools/checkNonIndexedBiblios.pl | 8 --- > misc/migration_tools/create_analytical_rel.pl | 6 --- > misc/migration_tools/import_lexile.pl | 8 --- > .../switch_marc21_series_info.pl | 7 --- > misc/stage_file.pl | 6 --- > t/db_dependent/00-strict.t | 1 - > xt/yaml_valid.t | 5 -- > 64 files changed, 459 deletions(-) > delete mode 100755 misc/kohalib.pl > >diff --git a/Makefile.PL b/Makefile.PL >index 976204f92b..2534e85ca3 100644 >--- a/Makefile.PL >+++ b/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' > ); > } > >diff --git a/misc/add_date_fields_to_marc_records.pl b/misc/add_date_fields_to_marc_records.pl >index f619f521c4..c310350b6a 100755 >--- a/misc/add_date_fields_to_marc_records.pl >+++ b/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 ); >diff --git a/misc/batchCompareMARCvsFrameworks.pl b/misc/batchCompareMARCvsFrameworks.pl >index ca5c8617ac..ae2c2e54d2 100755 >--- a/misc/batchCompareMARCvsFrameworks.pl >+++ b/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; >diff --git a/misc/batchDeleteUnusedSubfields.pl b/misc/batchDeleteUnusedSubfields.pl >index 1cfaf3c473..800465e545 100755 >--- a/misc/batchDeleteUnusedSubfields.pl >+++ b/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; >diff --git a/misc/batchImportMARCWithBiblionumbers.pl b/misc/batchImportMARCWithBiblionumbers.pl >index b96e0122aa..484f5171e5 100755 >--- a/misc/batchImportMARCWithBiblionumbers.pl >+++ b/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 > >diff --git a/misc/batchRebuildBiblioTables.pl b/misc/batchRebuildBiblioTables.pl >index ce4782f844..cb936c0c92 100755 >--- a/misc/batchRebuildBiblioTables.pl >+++ b/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; >diff --git a/misc/batchRepairMissingBiblionumbers.pl b/misc/batchRepairMissingBiblionumbers.pl >index 32e9913fd6..5a2d31fd30 100755 >--- a/misc/batchRepairMissingBiblionumbers.pl >+++ b/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; >diff --git a/misc/commit_file.pl b/misc/commit_file.pl >index 543d7b06c7..1e1dd3f4fe 100755 >--- a/misc/commit_file.pl >+++ b/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; >diff --git a/misc/cronjobs/advance_notices.pl b/misc/cronjobs/advance_notices.pl >index c1d6ac6672..2c8e6c2ecc 100755 >--- a/misc/cronjobs/advance_notices.pl >+++ b/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; >diff --git a/misc/cronjobs/batch_anonymise.pl b/misc/cronjobs/batch_anonymise.pl >index 6e05d36ce9..edea4fa7ed 100755 >--- a/misc/cronjobs/batch_anonymise.pl >+++ b/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; >diff --git a/misc/cronjobs/build_browser_and_cloud.pl b/misc/cronjobs/build_browser_and_cloud.pl >index 46551ca041..8cd733a785 100755 >--- a/misc/cronjobs/build_browser_and_cloud.pl >+++ b/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; >diff --git a/misc/cronjobs/cart_to_shelf.pl b/misc/cronjobs/cart_to_shelf.pl >index 264e933804..3c7d12e22b 100755 >--- a/misc/cronjobs/cart_to_shelf.pl >+++ b/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 ); > >diff --git a/misc/cronjobs/cleanup_database.pl b/misc/cronjobs/cleanup_database.pl >index abc7d180da..7d22d5d5d1 100755 >--- a/misc/cronjobs/cleanup_database.pl >+++ b/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; >diff --git a/misc/cronjobs/delete_records_via_leader.pl b/misc/cronjobs/delete_records_via_leader.pl >index 8456f42c04..2794efb8d7 100755 >--- a/misc/cronjobs/delete_records_via_leader.pl >+++ b/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; >diff --git a/misc/cronjobs/gather_print_notices.pl b/misc/cronjobs/gather_print_notices.pl >index a777acbbcf..488ce0791e 100755 >--- a/misc/cronjobs/gather_print_notices.pl >+++ b/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; >diff --git a/misc/cronjobs/holds/auto_unsuspend_holds.pl b/misc/cronjobs/holds/auto_unsuspend_holds.pl >index fdaa350159..a0b3724c98 100755 >--- a/misc/cronjobs/holds/auto_unsuspend_holds.pl >+++ b/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; >diff --git a/misc/cronjobs/holds/build_holds_queue.pl b/misc/cronjobs/holds/build_holds_queue.pl >index 6e1437dcd3..6ba476b585 100755 >--- a/misc/cronjobs/holds/build_holds_queue.pl >+++ b/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); >diff --git a/misc/cronjobs/holds/cancel_expired_holds.pl b/misc/cronjobs/holds/cancel_expired_holds.pl >index 3cc9152d17..a4addc0170 100755 >--- a/misc/cronjobs/holds/cancel_expired_holds.pl >+++ b/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 ); >diff --git a/misc/cronjobs/holds/cancel_unfilled_holds.pl b/misc/cronjobs/holds/cancel_unfilled_holds.pl >index 10952695b5..ea5d70ab48 100755 >--- a/misc/cronjobs/holds/cancel_unfilled_holds.pl >+++ b/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 ); > >diff --git a/misc/cronjobs/holds/holds_reminder.pl b/misc/cronjobs/holds/holds_reminder.pl >index ee9d5a13c6..3402dd16ec 100755 >--- a/misc/cronjobs/holds/holds_reminder.pl >+++ b/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; >diff --git a/misc/cronjobs/import_webservice_batch.pl b/misc/cronjobs/import_webservice_batch.pl >index 5925be2ea6..5274410d73 100755 >--- a/misc/cronjobs/import_webservice_batch.pl >+++ b/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 ); >diff --git a/misc/cronjobs/longoverdue.pl b/misc/cronjobs/longoverdue.pl >index dd12b6c104..457ddf4465 100755 >--- a/misc/cronjobs/longoverdue.pl >+++ b/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 ); >diff --git a/misc/cronjobs/membership_expiry.pl b/misc/cronjobs/membership_expiry.pl >index 41003674e2..c52843c7dc 100755 >--- a/misc/cronjobs/membership_expiry.pl >+++ b/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; >diff --git a/misc/cronjobs/overdue_notices.pl b/misc/cronjobs/overdue_notices.pl >index a1c2211628..36fe458ecc 100755 >--- a/misc/cronjobs/overdue_notices.pl >+++ b/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; >diff --git a/misc/cronjobs/patron_emailer.pl b/misc/cronjobs/patron_emailer.pl >index a265b762a9..a33600d528 100755 >--- a/misc/cronjobs/patron_emailer.pl >+++ b/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 ); >diff --git a/misc/cronjobs/process_message_queue.pl b/misc/cronjobs/process_message_queue.pl >index 79f09357bf..d8918be607 100755 >--- a/misc/cronjobs/process_message_queue.pl >+++ b/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 ); >diff --git a/misc/cronjobs/purge_suggestions.pl b/misc/cronjobs/purge_suggestions.pl >index 881ad7d4ea..7b55efb1aa 100755 >--- a/misc/cronjobs/purge_suggestions.pl >+++ b/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; >diff --git a/misc/cronjobs/reconcile_balances.pl b/misc/cronjobs/reconcile_balances.pl >index 4c55836091..ce95202b7e 100755 >--- a/misc/cronjobs/reconcile_balances.pl >+++ b/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 ); > >diff --git a/misc/cronjobs/runreport.pl b/misc/cronjobs/runreport.pl >index 710de44f3d..b3ce925350 100755 >--- a/misc/cronjobs/runreport.pl >+++ b/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 >diff --git a/misc/cronjobs/serialsUpdate.pl b/misc/cronjobs/serialsUpdate.pl >index 53d60071b4..26ebf25dde 100755 >--- a/misc/cronjobs/serialsUpdate.pl >+++ b/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 ); >diff --git a/misc/cronjobs/staticfines.pl b/misc/cronjobs/staticfines.pl >index 6d7cf733c4..d4141b25f3 100755 >--- a/misc/cronjobs/staticfines.pl >+++ b/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; >diff --git a/misc/cronjobs/thirdparty/TalkingTech_itiva_inbound.pl b/misc/cronjobs/thirdparty/TalkingTech_itiva_inbound.pl >index 6be0226433..6b876c9dbb 100755 >--- a/misc/cronjobs/thirdparty/TalkingTech_itiva_inbound.pl >+++ b/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 ); > >diff --git a/misc/cronjobs/thirdparty/TalkingTech_itiva_outbound.pl b/misc/cronjobs/thirdparty/TalkingTech_itiva_outbound.pl >index fedc3cf888..6a1456987f 100755 >--- a/misc/cronjobs/thirdparty/TalkingTech_itiva_outbound.pl >+++ b/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 ); > >diff --git a/misc/cronjobs/update_patrons_category.pl b/misc/cronjobs/update_patrons_category.pl >index 05f0b3c114..8ef7fe76d6 100755 >--- a/misc/cronjobs/update_patrons_category.pl >+++ b/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 ); >diff --git a/misc/cronjobs/update_totalissues.pl b/misc/cronjobs/update_totalissues.pl >index b3a6c2f503..a3f561bbf5 100755 >--- a/misc/cronjobs/update_totalissues.pl >+++ b/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 ); > >diff --git a/misc/exportauth.pl b/misc/exportauth.pl >index d2ccebf614..14e30884d2 100755 >--- a/misc/exportauth.pl >+++ b/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; >diff --git a/misc/kohalib.pl b/misc/kohalib.pl >deleted file mode 100755 >index 6c20190e66..0000000000 >--- a/misc/kohalib.pl >+++ /dev/null >@@ -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 <http://www.gnu.org/licenses>. >- >-# 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; >diff --git a/misc/link_bibs_to_authorities.pl b/misc/link_bibs_to_authorities.pl >index dc3de81816..8de9b683a6 100755 >--- a/misc/link_bibs_to_authorities.pl >+++ b/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( >diff --git a/misc/load_testing/benchmark_circulation.pl b/misc/load_testing/benchmark_circulation.pl >index 83ddea5461..0cedf19024 100755 >--- a/misc/load_testing/benchmark_circulation.pl >+++ b/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; >diff --git a/misc/load_testing/benchmark_staff.pl b/misc/load_testing/benchmark_staff.pl >index f42c4d5eaf..9ff8e9b676 100755 >--- a/misc/load_testing/benchmark_staff.pl >+++ b/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; >diff --git a/misc/maintenance/UNIMARC_fix_collectiontitle.pl b/misc/maintenance/UNIMARC_fix_collectiontitle.pl >index d28163a9b9..0577878e91 100755 >--- a/misc/maintenance/UNIMARC_fix_collectiontitle.pl >+++ b/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 { >diff --git a/misc/maintenance/UNIMARC_sync_date_created_with_marc_biblio.pl b/misc/maintenance/UNIMARC_sync_date_created_with_marc_biblio.pl >index 1a4b864822..c787374eef 100755 >--- a/misc/maintenance/UNIMARC_sync_date_created_with_marc_biblio.pl >+++ b/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 ); >diff --git a/misc/maintenance/borrowers-force-messaging-defaults.pl b/misc/maintenance/borrowers-force-messaging-defaults.pl >index 9a0b1c0f08..7f2bba0c69 100755 >--- a/misc/maintenance/borrowers-force-messaging-defaults.pl >+++ b/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; >diff --git a/misc/maintenance/fix_accountlines_date.pl b/misc/maintenance/fix_accountlines_date.pl >index fb9ceacf3d..670b35dc01 100755 >--- a/misc/maintenance/fix_accountlines_date.pl >+++ b/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; >diff --git a/misc/maintenance/fix_accountlines_rmdupfines_bug8253.pl b/misc/maintenance/fix_accountlines_rmdupfines_bug8253.pl >index fd9d04751d..608c6aaa7b 100755 >--- a/misc/maintenance/fix_accountlines_rmdupfines_bug8253.pl >+++ b/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; > >diff --git a/misc/maintenance/fix_mysql_constraints.pl b/misc/maintenance/fix_mysql_constraints.pl >index b1784a01ef..79599cdac4 100755 >--- a/misc/maintenance/fix_mysql_constraints.pl >+++ b/misc/maintenance/fix_mysql_constraints.pl >@@ -18,13 +18,6 @@ > # along with Koha; if not, see <http://www.gnu.org/licenses>. > > 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 ); >diff --git a/misc/maintenance/touch_all_biblios.pl b/misc/maintenance/touch_all_biblios.pl >index 2c725ae5e8..c2259602b4 100755 >--- a/misc/maintenance/touch_all_biblios.pl >+++ b/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 ); >diff --git a/misc/maintenance/touch_all_items.pl b/misc/maintenance/touch_all_items.pl >index c253959959..ddc9a821ce 100755 >--- a/misc/maintenance/touch_all_items.pl >+++ b/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 ); >diff --git a/misc/migration_tools/22_to_30/convert_to_utf8.pl b/misc/migration_tools/22_to_30/convert_to_utf8.pl >index d854b0c6d3..8afbb4f541 100755 >--- a/misc/migration_tools/22_to_30/convert_to_utf8.pl >+++ b/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"); >diff --git a/misc/migration_tools/22_to_30/export_Authorities.pl b/misc/migration_tools/22_to_30/export_Authorities.pl >index 3c5eb116f7..bed75f27c7 100755 >--- a/misc/migration_tools/22_to_30/export_Authorities.pl >+++ b/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; >diff --git a/misc/migration_tools/22_to_30/export_Authorities_xml.pl b/misc/migration_tools/22_to_30/export_Authorities_xml.pl >index ab058b5b04..2aefe5b62d 100755 >--- a/misc/migration_tools/22_to_30/export_Authorities_xml.pl >+++ b/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; >diff --git a/misc/migration_tools/22_to_30/missing090field.pl b/misc/migration_tools/22_to_30/missing090field.pl >index 80861b1865..a75fb24ead 100755 >--- a/misc/migration_tools/22_to_30/missing090field.pl >+++ b/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 > >diff --git a/misc/migration_tools/22_to_30/move_marc_to_authheader.pl b/misc/migration_tools/22_to_30/move_marc_to_authheader.pl >index 8a5ffa9354..53069bff01 100755 >--- a/misc/migration_tools/22_to_30/move_marc_to_authheader.pl >+++ b/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; >diff --git a/misc/migration_tools/22_to_30/move_marc_to_biblioitems.pl b/misc/migration_tools/22_to_30/move_marc_to_biblioitems.pl >index e4429a7d9e..417cc3a1f9 100755 >--- a/misc/migration_tools/22_to_30/move_marc_to_biblioitems.pl >+++ b/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' ); >diff --git a/misc/migration_tools/22_to_30/rebuild_leader.pl b/misc/migration_tools/22_to_30/rebuild_leader.pl >index 885ba459b2..77475f0fa4 100755 >--- a/misc/migration_tools/22_to_30/rebuild_leader.pl >+++ b/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 > >diff --git a/misc/migration_tools/22_to_30/rebuild_unimarc_100.pl b/misc/migration_tools/22_to_30/rebuild_unimarc_100.pl >index c9eddb5fc6..b9c976d71f 100755 >--- a/misc/migration_tools/22_to_30/rebuild_unimarc_100.pl >+++ b/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 > >diff --git a/misc/migration_tools/bulkmarcimport.pl b/misc/migration_tools/bulkmarcimport.pl >index 5cb9b7b63b..897e5a7ad0 100755 >--- a/misc/migration_tools/bulkmarcimport.pl >+++ b/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; >diff --git a/misc/migration_tools/checkNonIndexedBiblios.pl b/misc/migration_tools/checkNonIndexedBiblios.pl >index 25b58ea7e3..490b226912 100755 >--- a/misc/migration_tools/checkNonIndexedBiblios.pl >+++ b/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; >diff --git a/misc/migration_tools/create_analytical_rel.pl b/misc/migration_tools/create_analytical_rel.pl >index dfdd10e26a..370d92b0e8 100755 >--- a/misc/migration_tools/create_analytical_rel.pl >+++ b/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; >diff --git a/misc/migration_tools/import_lexile.pl b/misc/migration_tools/import_lexile.pl >index b63768491e..784b5826f0 100755 >--- a/misc/migration_tools/import_lexile.pl >+++ b/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; >diff --git a/misc/migration_tools/switch_marc21_series_info.pl b/misc/migration_tools/switch_marc21_series_info.pl >index f3962e5649..39e0db1fdd 100755 >--- a/misc/migration_tools/switch_marc21_series_info.pl >+++ b/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; >diff --git a/misc/stage_file.pl b/misc/stage_file.pl >index f05be7a01d..90d2b6ebc4 100755 >--- a/misc/stage_file.pl >+++ b/misc/stage_file.pl >@@ -20,12 +20,6 @@ > # along with Koha; if not, see <http://www.gnu.org/licenses>. > > 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; >diff --git a/t/db_dependent/00-strict.t b/t/db_dependent/00-strict.t >index 74212e8f8a..eb2ea52537 100755 >--- a/t/db_dependent/00-strict.t >+++ b/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} ) { >diff --git a/xt/yaml_valid.t b/xt/yaml_valid.t >index b6f3c600d8..b37dbb4eaa 100755 >--- a/xt/yaml_valid.t >+++ b/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; >-- >2.20.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 28617
:
122935
|
127916
|
127917
| 128063 |
128064