From: Donovan Jones Date: Fri, 16 Apr 2010 04:18:23 +0000 (+1200) Subject: Bug 2505 - Add commented use warnings where missing in the misc/ directory X-Git-Tag: v3.02.00-alpha2~122^2~7 X-Git-Url: http://git.rot13.org/?a=commitdiff_plain;h=5e0b850d49f452ffbca41f47dc190d6d4f2323c7;p=koha.git Bug 2505 - Add commented use warnings where missing in the misc/ directory --- diff --git a/misc/batchCompareMARCvsFrameworks.pl b/misc/batchCompareMARCvsFrameworks.pl index b0ed79736b..9bbcde46df 100755 --- a/misc/batchCompareMARCvsFrameworks.pl +++ b/misc/batchCompareMARCvsFrameworks.pl @@ -3,6 +3,7 @@ use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/batchDeleteUnusedSubfields.pl b/misc/batchDeleteUnusedSubfields.pl index eca83ddefe..a0ecb5cece 100755 --- a/misc/batchDeleteUnusedSubfields.pl +++ b/misc/batchDeleteUnusedSubfields.pl @@ -2,6 +2,7 @@ # small script that rebuilds the non-MARC DB use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/batchImportMARCWithBiblionumbers.pl b/misc/batchImportMARCWithBiblionumbers.pl index a1bf26eb74..4acc02b116 100755 --- a/misc/batchImportMARCWithBiblionumbers.pl +++ b/misc/batchImportMARCWithBiblionumbers.pl @@ -2,6 +2,7 @@ # load records that already have biblionumber set into a koha system # 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 diff --git a/misc/batchRebuildBiblioTables.pl b/misc/batchRebuildBiblioTables.pl index 8e1c3aca3e..b15a91ade7 100755 --- a/misc/batchRebuildBiblioTables.pl +++ b/misc/batchRebuildBiblioTables.pl @@ -3,7 +3,7 @@ # Formerly named rebuildnonmarc.pl use strict; -# use warnings; FIXME someday +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules diff --git a/misc/batchupdateISBNs.pl b/misc/batchupdateISBNs.pl index 03d5bba82f..8cc8c6ac20 100755 --- a/misc/batchupdateISBNs.pl +++ b/misc/batchupdateISBNs.pl @@ -24,6 +24,7 @@ =cut use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/bin/zebraqueue_daemon.pl b/misc/bin/zebraqueue_daemon.pl index 7e62c944e1..6181a94c03 100755 --- a/misc/bin/zebraqueue_daemon.pl +++ b/misc/bin/zebraqueue_daemon.pl @@ -3,6 +3,7 @@ # daemon to watch the zebraqueue and update zebra as needed use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/check_sysprefs.pl b/misc/check_sysprefs.pl index 06ed80644e..68238087e9 100755 --- a/misc/check_sysprefs.pl +++ b/misc/check_sysprefs.pl @@ -5,6 +5,9 @@ # export PERL5LIB # then ./check_sysprefs.pl path (if path is blank it will use .) +#use strict; +#use warnings; FIXME - Bug 2505 + use File::Find; use C4::Context; diff --git a/misc/commit_biblios_file.pl b/misc/commit_biblios_file.pl index 2f9851fe82..5e3010e7a3 100755 --- a/misc/commit_biblios_file.pl +++ b/misc/commit_biblios_file.pl @@ -1,6 +1,7 @@ #!/usr/bin/perl use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/cronjobs/build_browser_and_cloud.pl b/misc/cronjobs/build_browser_and_cloud.pl index e1873c816f..d3ead43c30 100755 --- a/misc/cronjobs/build_browser_and_cloud.pl +++ b/misc/cronjobs/build_browser_and_cloud.pl @@ -2,6 +2,7 @@ # small script that builds the tag cloud use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/cronjobs/fines.pl b/misc/cronjobs/fines.pl index 1d0cdc0e5d..73cdf9f81b 100755 --- a/misc/cronjobs/fines.pl +++ b/misc/cronjobs/fines.pl @@ -28,6 +28,7 @@ # FIXME: use FinesMode as described or change syspref description use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules diff --git a/misc/cronjobs/holds/cancel_expired_holds.pl b/misc/cronjobs/holds/cancel_expired_holds.pl index c14c261d2e..70a2f59284 100755 --- a/misc/cronjobs/holds/cancel_expired_holds.pl +++ b/misc/cronjobs/holds/cancel_expired_holds.pl @@ -17,6 +17,9 @@ # with Koha; if not, write to the Free Software Foundation, Inc., # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. +#use strict; +#use warnings; FIXME - Bug 2505 + BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/cronjobs/j2a.pl b/misc/cronjobs/j2a.pl index de648ca290..ec5d207d8f 100755 --- a/misc/cronjobs/j2a.pl +++ b/misc/cronjobs/j2a.pl @@ -1,6 +1,7 @@ #!/usr/bin/perl #run nightly -- changes J to A on someone's 18th birthday use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/cronjobs/notifyMailsOp.pl b/misc/cronjobs/notifyMailsOp.pl index e44ab78ec6..630b1591c3 100755 --- a/misc/cronjobs/notifyMailsOp.pl +++ b/misc/cronjobs/notifyMailsOp.pl @@ -1,5 +1,6 @@ #!/usr/bin/perl use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/cronjobs/smsoverdues.pl b/misc/cronjobs/smsoverdues.pl index c2a691315f..f4dda399b2 100755 --- a/misc/cronjobs/smsoverdues.pl +++ b/misc/cronjobs/smsoverdues.pl @@ -27,6 +27,9 @@ # $Id: sendoverdues.pl,v 1.1.2.1 2007/03/26 22:38:09 tgarip1957 Exp $ +#use strict; +#use warnings; FIXME - Bug 2505 + BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/cronjobs/zebraqueue_start.pl b/misc/cronjobs/zebraqueue_start.pl index 52c8fe0ef7..ea84156793 100755 --- a/misc/cronjobs/zebraqueue_start.pl +++ b/misc/cronjobs/zebraqueue_start.pl @@ -2,6 +2,7 @@ # script that starts the zebraquee # Written by TG on 01/08/2006 use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/exportauth.pl b/misc/exportauth.pl index 52a0ec8971..4ac916c4d0 100755 --- a/misc/exportauth.pl +++ b/misc/exportauth.pl @@ -4,6 +4,7 @@ # use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/kohalib.pl b/misc/kohalib.pl index b5e1f191be..e0add492b0 100755 --- a/misc/kohalib.pl +++ b/misc/kohalib.pl @@ -39,6 +39,7 @@ # use strict; +#use warnings; FIXME - Bug 2505 my $module_dir; BEGIN { diff --git a/misc/link_bibs_to_authorities.pl b/misc/link_bibs_to_authorities.pl index 9954fd66bf..e3f9bdc824 100755 --- a/misc/link_bibs_to_authorities.pl +++ b/misc/link_bibs_to_authorities.pl @@ -1,6 +1,7 @@ #!/usr/bin/perl use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/maintenance/sync_items_in_marc_bib.pl b/misc/maintenance/sync_items_in_marc_bib.pl index af89769a89..d3eb2efe95 100755 --- a/misc/maintenance/sync_items_in_marc_bib.pl +++ b/misc/maintenance/sync_items_in_marc_bib.pl @@ -1,6 +1,7 @@ #!/usr/bin/perl use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/migration_tools/22_to_30/export_Authorities.pl b/misc/migration_tools/22_to_30/export_Authorities.pl index 8327cf7805..aeed3f2fa0 100755 --- a/misc/migration_tools/22_to_30/export_Authorities.pl +++ b/misc/migration_tools/22_to_30/export_Authorities.pl @@ -1,4 +1,6 @@ #!/usr/bin/perl +#use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this 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 635a4145f8..70647ee7a1 100755 --- a/misc/migration_tools/22_to_30/export_Authorities_xml.pl +++ b/misc/migration_tools/22_to_30/export_Authorities_xml.pl @@ -1,4 +1,6 @@ #!/usr/bin/perl +#use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/migration_tools/22_to_30/missing090field.pl b/misc/migration_tools/22_to_30/missing090field.pl index 648788ba18..aae803236d 100755 --- a/misc/migration_tools/22_to_30/missing090field.pl +++ b/misc/migration_tools/22_to_30/missing090field.pl @@ -3,6 +3,7 @@ # Written by TG on 01/10/2005 # 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 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 deffc7090d..2546da855b 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 @@ -2,6 +2,8 @@ # script to shift marc to biblioitems # 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 @@ -13,7 +15,6 @@ use C4::AuthoritiesMarc; use MARC::Record; use MARC::File::XML ( BinaryEncoding => 'utf8' ); -use strict; print "moving MARC record to marc_header table\n"; my $dbh = C4::Context->dbh(); 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 883af15f17..3635dbc386 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 @@ -1,5 +1,6 @@ #!/usr/bin/perl - +#use strict; +#use warnings; FIXME - Bug 2505 # script to shift marc to biblioitems # scraped from updatedatabase for dev week by chris@katipo.co.nz BEGIN { diff --git a/misc/migration_tools/22_to_30/rebuild_leader.pl b/misc/migration_tools/22_to_30/rebuild_leader.pl index 0ab0f07cf6..ded81b3730 100755 --- a/misc/migration_tools/22_to_30/rebuild_leader.pl +++ b/misc/migration_tools/22_to_30/rebuild_leader.pl @@ -3,6 +3,7 @@ # Written by TG on 01/10/2005 # 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 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 1ef4049fbd..320ced2684 100755 --- a/misc/migration_tools/22_to_30/rebuild_unimarc_100.pl +++ b/misc/migration_tools/22_to_30/rebuild_unimarc_100.pl @@ -3,6 +3,7 @@ # Written by TG on 01/10/2005 # 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 diff --git a/misc/migration_tools/build6xx.pl b/misc/migration_tools/build6xx.pl index 1c038ee2a6..5c02f12f3f 100755 --- a/misc/migration_tools/build6xx.pl +++ b/misc/migration_tools/build6xx.pl @@ -3,6 +3,7 @@ # delete FROM `marc_subfield_table` WHERE tag = "606" AND subfieldcode = 9; use strict; +#use warnings; FIXME - Bug 2505 # Koha modules used use MARC::File::USMARC; diff --git a/misc/migration_tools/buildCOUNTRY.pl b/misc/migration_tools/buildCOUNTRY.pl index 850ea17786..9fb657007d 100755 --- a/misc/migration_tools/buildCOUNTRY.pl +++ b/misc/migration_tools/buildCOUNTRY.pl @@ -3,6 +3,7 @@ # delete FROM `marc_subfield_table` WHERE tag = "606" AND subfieldcode = 9; use strict; +#use warnings; FIXME - Bug 2505 # Koha modules used use C4::Context; diff --git a/misc/migration_tools/buildEDITORS.pl b/misc/migration_tools/buildEDITORS.pl index e6d6fd3161..0126ae614a 100755 --- a/misc/migration_tools/buildEDITORS.pl +++ b/misc/migration_tools/buildEDITORS.pl @@ -2,6 +2,7 @@ # script that rebuild EDITORS use strict; +#use warnings; FIXME - Bug 2505 # Koha modules used use MARC::File::USMARC; diff --git a/misc/migration_tools/buildLANG.pl b/misc/migration_tools/buildLANG.pl index fe9e6d5e23..bd33212749 100755 --- a/misc/migration_tools/buildLANG.pl +++ b/misc/migration_tools/buildLANG.pl @@ -3,6 +3,7 @@ # delete FROM `marc_subfield_table` WHERE tag = "606" AND subfieldcode = 9; use strict; +#use warnings; FIXME - Bug 2505 # Koha modules used use C4::Context; diff --git a/misc/migration_tools/bulkauthimport.pl b/misc/migration_tools/bulkauthimport.pl index d3dcadcea7..2709db91c9 100755 --- a/misc/migration_tools/bulkauthimport.pl +++ b/misc/migration_tools/bulkauthimport.pl @@ -2,6 +2,7 @@ # small script that import an iso2709 file into koha 2.0 use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/migration_tools/fix_onloan.pl b/misc/migration_tools/fix_onloan.pl index 1dc5246af7..d6e63af79a 100755 --- a/misc/migration_tools/fix_onloan.pl +++ b/misc/migration_tools/fix_onloan.pl @@ -1,6 +1,7 @@ #!/usr/bin/perl use strict; +#use warnings; FIXME - Bug 2505 use C4::Context; use C4::Items; use C4::Biblio; @@ -24,4 +25,4 @@ $|=1; while (my ($biblionumber,$itemnumber,$onloan)= $rqbiblios->fetchrow){ ModItem({onloan => "$onloan"}, $biblionumber, $itemnumber); print "Onloan : $onloan for $biblionumber / $itemnumber\n"; -} \ No newline at end of file +} diff --git a/misc/migration_tools/merge_authority.pl b/misc/migration_tools/merge_authority.pl index 8bf4e7c325..0987827981 100755 --- a/misc/migration_tools/merge_authority.pl +++ b/misc/migration_tools/merge_authority.pl @@ -2,6 +2,7 @@ # script that rebuild thesaurus from biblio table. use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/migration_tools/rebuild_nozebra.pl b/misc/migration_tools/rebuild_nozebra.pl index 7432c5e6b4..b6b82c5c8c 100755 --- a/misc/migration_tools/rebuild_nozebra.pl +++ b/misc/migration_tools/rebuild_nozebra.pl @@ -6,6 +6,7 @@ use C4::Biblio; use C4::AuthoritiesMarc; use strict; +#use warnings; FIXME - Bug 2505 # # script that fills the nozebra table # diff --git a/misc/migration_tools/rebuild_zebra.pl b/misc/migration_tools/rebuild_zebra.pl index 0f4b4a0b13..37dcaf508d 100755 --- a/misc/migration_tools/rebuild_zebra.pl +++ b/misc/migration_tools/rebuild_zebra.pl @@ -1,6 +1,7 @@ #!/usr/bin/perl use strict; +#use warnings; FIXME - Bug 2505 use C4::Context; use Getopt::Long; diff --git a/misc/migration_tools/upgradeitems.pl b/misc/migration_tools/upgradeitems.pl index 864c91b7e4..10c754433a 100755 --- a/misc/migration_tools/upgradeitems.pl +++ b/misc/migration_tools/upgradeitems.pl @@ -1,6 +1,7 @@ #!/usr/bin/perl use strict; +#use warnings; FIXME - Bug 2505 use C4::Context; use C4::Items; use C4::Biblio; @@ -27,4 +28,4 @@ while (my ($biblionumber)= $rqbiblios->fetchrow_array){ warn $record->as_formatted; } } -} \ No newline at end of file +} diff --git a/misc/perlmodule_ls.pl b/misc/perlmodule_ls.pl index 818f855cc2..6ffcc528fd 100755 --- a/misc/perlmodule_ls.pl +++ b/misc/perlmodule_ls.pl @@ -1,5 +1,8 @@ #!/usr/bin/perl +#use strict; +#use warnings; FIXME - Bug 2505 + use ExtUtils::Installed; my $instmod = ExtUtils::Installed->new(); foreach my $module ($instmod->modules()) { diff --git a/misc/sax_parser_test.pl b/misc/sax_parser_test.pl index 07d672cf09..c99f07bad2 100755 --- a/misc/sax_parser_test.pl +++ b/misc/sax_parser_test.pl @@ -1,4 +1,6 @@ #!/usr/bin/perl +#use strict; +#use warnings; FIXME - Bug 2505 use XML::SAX; my $parser = XML::SAX::ParserFactory->parser( Handler => MySAXHandler->new diff --git a/misc/stage_biblios_file.pl b/misc/stage_biblios_file.pl index 5518359dcc..3f18082104 100755 --- a/misc/stage_biblios_file.pl +++ b/misc/stage_biblios_file.pl @@ -1,6 +1,7 @@ #!/usr/bin/perl use strict; +#use warnings; FIXME - Bug 2505 BEGIN { # find Koha's Perl modules # test carefully before changing this diff --git a/misc/translator/stats.pl b/misc/translator/stats.pl index 8ba923bf51..1f1c6319cf 100755 --- a/misc/translator/stats.pl +++ b/misc/translator/stats.pl @@ -18,6 +18,8 @@ # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. # +#use strict; +#use warnings; FIXME - Bug 2505 my $PACKAGE="koha"; diff --git a/misc/translator/text-extract.pl b/misc/translator/text-extract.pl index f876e78195..4e2fbdce77 100755 --- a/misc/translator/text-extract.pl +++ b/misc/translator/text-extract.pl @@ -1,4 +1,6 @@ #!/usr/bin/perl +#use strict; +#use warnings; FIXME - Bug 2505 use HTML::Tree; use Getopt::Std; getopt("f:"); diff --git a/misc/translator/text-extract2.pl b/misc/translator/text-extract2.pl index ec838c80ec..452fd89666 100755 --- a/misc/translator/text-extract2.pl +++ b/misc/translator/text-extract2.pl @@ -14,10 +14,11 @@ # --> This will be relatively major rework, and requires corresponding # rework in tmpl_process.pl +use strict; +#use warnings; FIXME - Bug 2505 use Getopt::Long; use TmplTokenizer; use VerboseWarnings; -use strict; use vars qw( $input ); use vars qw( $debug_dump_only_p ); diff --git a/misc/translator/tmpl_process3.pl b/misc/translator/tmpl_process3.pl index 80325d077f..dbbe18e9b3 100755 --- a/misc/translator/tmpl_process3.pl +++ b/misc/translator/tmpl_process3.pl @@ -12,6 +12,7 @@ using gettext-compatible translation files =cut use strict; +#use warnings; FIXME - Bug 2505 use Getopt::Long; use Locale::PO; use File::Temp qw( :POSIX );