From 53ab95f49d1bd2045859a5b5ace7b17530708d80 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Fri, 21 May 2021 17:14:22 +0200 Subject: [PATCH] Bug 17600: After perlimports find . -name '*.pm' -o -name '*.pl' -exec perl App-perlimports/script/perlimports --inplace-edit --no-preserve-unused --filename {} \; --- about.pl | 21 ++++----- acqui/acqui-home.pl | 1 - acqui/add_user_search.pl | 0 acqui/addorder.pl | 13 ++++-- acqui/addorderiso2709.pl | 18 +++++--- acqui/ajax-getauthvaluedropbox.pl | 2 +- acqui/basket.pl | 9 ++-- acqui/basketgroup.pl | 22 ++++++++-- acqui/basketheader.pl | 2 +- acqui/booksellers.pl | 1 - acqui/cancelorder.pl | 2 +- acqui/check_budget_total.pl | 0 acqui/check_uniqueness.pl | 4 +- acqui/duplicate_orders.pl | 2 +- acqui/edi_ean.pl | 3 +- acqui/edifactmsgs.pl | 3 +- acqui/edimsg.pl | 2 +- acqui/finishreceive.pl | 3 +- acqui/histsearch.pl | 4 +- acqui/invoice-files.pl | 2 +- acqui/invoice.pl | 2 +- acqui/invoices.pl | 2 +- acqui/lateorders-export.pl | 2 +- acqui/lateorders.pl | 5 +-- acqui/modordernotes.pl | 0 acqui/neworderempty.pl | 14 ++++-- acqui/newordersubscription.pl | 0 acqui/newordersuggestion.pl | 1 - acqui/ordered.pl | 0 acqui/orderreceive.pl | 2 - acqui/parcel.pl | 4 -- acqui/parcels.pl | 2 +- acqui/showorder.pl | 0 acqui/spent.pl | 0 acqui/supplier.pl | 3 +- acqui/transferorder.pl | 0 acqui/uncertainprice.pl | 1 - acqui/updatesupplier.pl | 2 - acqui/z3950_search.pl | 1 - admin/add_user_search.pl | 0 admin/additional-fields.pl | 3 +- admin/admin-home.pl | 0 admin/adveditorshortcuts.pl | 2 - admin/aqbudgetperiods.pl | 5 +-- admin/aqbudgets.pl | 3 -- admin/aqcontract.pl | 10 ++++- admin/aqplan.pl | 8 ++-- admin/audio_alerts.pl | 2 +- admin/auth_subfields_structure.pl | 1 - admin/auth_tag_structure.pl | 1 - admin/authorised_values.pl | 4 +- admin/authtypes.pl | 0 admin/background_jobs.pl | 2 - admin/biblio_framework.pl | 0 admin/branch_transfer_limits.pl | 1 - admin/branches.pl | 3 +- admin/cash_registers.pl | 4 +- admin/categories.pl | 2 +- admin/check_budget_parent.pl | 0 admin/check_parent_total.pl | 0 admin/checkmarc.pl | 1 - admin/cities.pl | 0 admin/classsources.pl | 1 - admin/clone-rules.pl | 2 - admin/columns_settings.pl | 2 +- admin/credit_types.pl | 2 +- admin/currency.pl | 0 admin/debit_types.pl | 2 +- admin/desks.pl | 0 admin/didyoumean.pl | 4 +- admin/edi_accounts.pl | 2 +- admin/edi_ean_accounts.pl | 2 +- admin/import_export_framework.pl | 2 +- admin/item_circulation_alerts.pl | 4 +- admin/items_search_field.pl | 2 +- admin/items_search_fields.pl | 2 +- admin/itemtypes.pl | 1 - admin/koha2marclinks.pl | 1 - admin/library_groups.pl | 0 admin/localization.pl | 0 admin/marc_subfields_structure.pl | 0 admin/marctagstructure.pl | 1 - admin/matching-rules.pl | 1 - admin/oai_set_mappings.pl | 3 +- admin/oai_sets.pl | 3 +- admin/overdrive.pl | 0 admin/patron-attr-types.pl | 3 +- admin/preferences.pl | 12 +++-- admin/searchengine/elasticsearch/mappings.pl | 10 ++--- admin/share_content.pl | 2 +- admin/smart-rules.pl | 5 +-- admin/sms_providers.pl | 2 +- admin/smtp_servers.pl | 4 +- admin/sru_modmapping.pl | 2 +- admin/systempreferences.pl | 6 +-- admin/transfer_limits.pl | 1 - admin/transport-cost-matrix.pl | 3 -- admin/usage_statistics.pl | 2 +- admin/z3950servers.pl | 0 api/v1/app.pl | 2 +- authorities/auth_finder.pl | 1 - authorities/authorities-home.pl | 3 +- authorities/authorities.pl | 3 +- authorities/blinddetail-biblio-search.pl | 2 - authorities/detail-biblio-search.pl | 2 - authorities/detail.pl | 3 +- authorities/export.pl | 0 authorities/merge.pl | 1 - authorities/merge_ajax.pl | 2 +- authorities/ysearch.pl | 2 +- basket/basket.pl | 11 ++++- basket/downloadcart.pl | 5 +-- basket/sendbasket.pl | 17 ++++--- catalogue/ISBDdetail.pl | 6 +-- catalogue/MARCdetail.pl | 17 ++++--- catalogue/detail.pl | 22 ++++++---- catalogue/export.pl | 2 +- catalogue/getitem-ajax.pl | 4 +- catalogue/image.pl | 0 catalogue/imageviewer.pl | 1 - catalogue/issuehistory.pl | 1 - catalogue/item-export.pl | 2 +- catalogue/itemsearch.pl | 5 +-- catalogue/labeledMARCdetail.pl | 11 +++-- catalogue/moredetail.pl | 5 +-- catalogue/search-history.pl | 0 catalogue/search.pl | 9 ++-- catalogue/showmarc.pl | 3 +- catalogue/stockrotation.pl | 2 +- catalogue/updateitem.pl | 2 - cataloguing/addbiblio.pl | 27 ++++++++---- cataloguing/addbooks.pl | 4 +- cataloguing/additem.pl | 28 ++++++++---- cataloguing/editor.pl | 4 +- cataloguing/linkitem.pl | 4 +- cataloguing/merge.pl | 14 ++++-- cataloguing/merge_ajax.pl | 2 +- cataloguing/moveitem.pl | 4 -- cataloguing/plugin_launcher.pl | 0 cataloguing/value_builder/EXAMPLE.pl | 0 cataloguing/value_builder/barcode.pl | 4 +- cataloguing/value_builder/barcode_manual.pl | 2 +- cataloguing/value_builder/callnumber-KU.pl | 0 cataloguing/value_builder/callnumber.pl | 0 cataloguing/value_builder/cn_browser.pl | 1 - cataloguing/value_builder/dateaccessioned.pl | 2 +- cataloguing/value_builder/macles.pl | 0 cataloguing/value_builder/marc21_field_005.pl | 0 cataloguing/value_builder/marc21_field_006.pl | 2 +- cataloguing/value_builder/marc21_field_007.pl | 0 cataloguing/value_builder/marc21_field_008.pl | 2 +- .../marc21_field_008_authorities.pl | 0 .../marc21_field_008_classifications.pl | 0 .../value_builder/marc21_field_245h.pl | 0 .../value_builder/marc21_field_260b.pl | 0 cataloguing/value_builder/marc21_leader.pl | 0 .../marc21_leader_authorities.pl | 0 .../value_builder/marc21_linking_section.pl | 2 - cataloguing/value_builder/marc21_orgcode.pl | 0 .../value_builder/normarc_field_007.pl | 0 .../value_builder/normarc_field_008.pl | 0 cataloguing/value_builder/normarc_leader.pl | 0 cataloguing/value_builder/stocknumber.pl | 0 cataloguing/value_builder/stocknumberAV.pl | 0 cataloguing/value_builder/stocknumberam123.pl | 0 .../value_builder/unimarc_field_010.pl | 0 .../value_builder/unimarc_field_100.pl | 2 +- .../unimarc_field_100_authorities.pl | 0 .../value_builder/unimarc_field_105.pl | 0 .../value_builder/unimarc_field_106.pl | 0 .../value_builder/unimarc_field_110.pl | 0 .../value_builder/unimarc_field_115a.pl | 0 .../value_builder/unimarc_field_115b.pl | 0 .../value_builder/unimarc_field_116.pl | 0 .../value_builder/unimarc_field_117.pl | 0 .../value_builder/unimarc_field_120.pl | 0 .../value_builder/unimarc_field_121a.pl | 0 .../value_builder/unimarc_field_121b.pl | 0 .../value_builder/unimarc_field_122.pl | 0 .../value_builder/unimarc_field_123a.pl | 0 .../value_builder/unimarc_field_123d.pl | 0 .../value_builder/unimarc_field_123e.pl | 0 .../value_builder/unimarc_field_123f.pl | 0 .../value_builder/unimarc_field_123g.pl | 0 .../value_builder/unimarc_field_123i.pl | 0 .../value_builder/unimarc_field_123j.pl | 0 .../value_builder/unimarc_field_124.pl | 0 .../value_builder/unimarc_field_124a.pl | 0 .../value_builder/unimarc_field_124b.pl | 0 .../value_builder/unimarc_field_124c.pl | 0 .../value_builder/unimarc_field_124d.pl | 0 .../value_builder/unimarc_field_124e.pl | 0 .../value_builder/unimarc_field_124f.pl | 0 .../value_builder/unimarc_field_124g.pl | 0 .../value_builder/unimarc_field_125.pl | 0 .../value_builder/unimarc_field_125a.pl | 0 .../value_builder/unimarc_field_125b.pl | 0 .../value_builder/unimarc_field_126.pl | 0 .../value_builder/unimarc_field_126a.pl | 0 .../value_builder/unimarc_field_126b.pl | 0 .../value_builder/unimarc_field_127.pl | 0 .../value_builder/unimarc_field_128a.pl | 0 .../value_builder/unimarc_field_128b.pl | 0 .../value_builder/unimarc_field_128c.pl | 0 .../value_builder/unimarc_field_130.pl | 0 .../value_builder/unimarc_field_135a.pl | 0 .../value_builder/unimarc_field_140.pl | 0 .../value_builder/unimarc_field_141.pl | 0 .../value_builder/unimarc_field_210c.pl | 1 - .../value_builder/unimarc_field_210c_bis.pl | 0 .../value_builder/unimarc_field_225a.pl | 0 .../value_builder/unimarc_field_225a_bis.pl | 0 .../value_builder/unimarc_field_4XX.pl | 2 - .../value_builder/unimarc_field_686a.pl | 0 .../value_builder/unimarc_field_700-4.pl | 0 cataloguing/value_builder/unimarc_leader.pl | 0 cataloguing/value_builder/upload.pl | 0 cataloguing/ysearch.pl | 2 +- cataloguing/z3950_auth_search.pl | 1 - cataloguing/z3950_search.pl | 1 - changelanguage.pl | 0 circ/add_message.pl | 0 circ/article-request-slip.pl | 2 +- circ/article-requests.pl | 0 circ/bookcount.pl | 3 -- circ/branchoverdues.pl | 6 +-- circ/branchtransfers.pl | 3 -- circ/checkout-notes.pl | 0 circ/circulation-home.pl | 0 circ/circulation.pl | 14 ++---- circ/del_message.pl | 0 circ/hold-transfer-slip.pl | 0 circ/offline-mf.pl | 0 circ/offline.pl | 0 circ/on-site_checkouts.pl | 1 - circ/overdue.pl | 6 +-- circ/pendingreserves.pl | 9 ++-- circ/renew.pl | 3 +- circ/request-article.pl | 0 circ/reserveratios.pl | 5 +-- circ/returns.pl | 6 +-- circ/set-library.pl | 1 - circ/transfer-slip.pl | 0 circ/transfers_to_send.pl | 2 +- circ/transferstoreceive.pl | 10 +---- circ/view_holdsqueue.pl | 2 - circ/waitingreserves.pl | 12 ++--- circ/ysearch.pl | 2 +- clubs/club-enrollments.pl | 2 +- clubs/clubs-add-modify.pl | 4 +- clubs/clubs.pl | 2 +- clubs/patron-clubs-tab.pl | 2 +- clubs/patron-enroll.pl | 2 +- clubs/templates-add-modify.pl | 4 +- course_reserves/add_items.pl | 1 - course_reserves/batch_add_items.pl | 0 course_reserves/batch_rm_items.pl | 0 course_reserves/course-details.pl | 1 - course_reserves/course-reserves.pl | 0 course_reserves/course.pl | 0 course_reserves/mod_course.pl | 0 docs/CAS/CASProxy/examples/koha_webservice.pl | 0 docs/CAS/CASProxy/examples/proxy_cas.pl | 0 .../CASProxy/examples/proxy_cas_callback.pl | 2 +- docs/CAS/CASProxy/examples/proxy_cas_data.pl | 5 +-- errors/400.pl | 2 +- errors/401.pl | 2 +- errors/402.pl | 2 +- errors/403.pl | 2 +- errors/404.pl | 2 +- errors/500.pl | 2 +- help.pl | 0 ill/ill-requests.pl | 8 ++-- installer/data/mysql/backfill_statistics.pl | 7 +-- ...fix_unclosed_nonaccruing_fines_bug17135.pl | 6 +-- installer/data/mysql/labels_upgrade.pl | 0 installer/data/mysql/patroncards_upgrade.pl | 0 installer/data/mysql/update22to30.pl | 4 +- installer/data/mysql/updatedatabase.pl | 19 ++++---- installer/externalmodules.pl | 0 .../html-template-to-template-toolkit.pl | 8 ++-- installer/install.pl | 4 +- installer/onboarding.pl | 2 +- koha_perl_deps.pl | 7 ++- kohaversion.pl | 0 labels/label-create-csv.pl | 5 +-- labels/label-create-pdf.pl | 3 +- labels/label-create-xml.pl | 5 +-- labels/label-edit-batch.pl | 2 +- labels/label-edit-layout.pl | 9 +++- labels/label-edit-profile.pl | 2 +- labels/label-edit-range.pl | 0 labels/label-edit-template.pl | 2 +- labels/label-home.pl | 0 labels/label-item-search.pl | 9 ++-- labels/label-manage.pl | 9 +++- labels/label-print.pl | 7 ++- labels/spinelabel-home.pl | 0 labels/spinelabel-print.pl | 0 mainpage.pl | 3 +- members/accountline-details.pl | 0 members/apikeys.pl | 2 +- members/boraccount.pl | 4 +- members/cancel-charge.pl | 2 +- members/default_messageprefs.pl | 0 members/deletemem.pl | 3 +- members/discharge.pl | 5 +-- members/discharges.pl | 2 +- members/files.pl | 2 - members/guarantor_search.pl | 0 members/holdshistory.pl | 0 members/housebound.pl | 4 +- members/ill-requests.pl | 0 members/mancredit.pl | 1 - members/maninvoice.pl | 3 +- members/member-flags.pl | 0 members/member-password.pl | 4 +- members/member.pl | 3 +- members/memberentry.pl | 8 ++-- members/members-home.pl | 2 +- members/members-update-do.pl | 0 members/members-update.pl | 0 members/merge-patrons.pl | 2 +- members/mod_debarment.pl | 4 +- members/moremember.pl | 5 +-- members/notices.pl | 2 +- members/patronimage.pl | 0 members/pay.pl | 9 +--- members/paycollect.pl | 7 +-- members/print_overdues.pl | 2 +- members/printfeercpt.pl | 2 +- members/printinvoice.pl | 2 +- members/printslip.pl | 2 - members/purchase-suggestions.pl | 0 members/readingrec.pl | 4 +- members/routing-lists.pl | 0 members/setstatus.pl | 1 - members/statistics.pl | 6 ++- members/summary-print.pl | 5 +-- members/update-child.pl | 0 misc/add_date_fields_to_marc_records.pl | 9 ++-- misc/admin/set_password.pl | 8 ++-- misc/background_jobs_worker.pl | 4 +- misc/batchCompareMARCvsFrameworks.pl | 8 ++-- misc/batchDeleteUnusedSubfields.pl | 8 ++-- misc/batchImportMARCWithBiblionumbers.pl | 10 ++--- misc/batchRebuildBiblioTables.pl | 18 +++++--- misc/batchRebuildItemsTables.pl | 12 ++--- misc/batchRepairMissingBiblionumbers.pl | 5 +-- misc/batchdeletebiblios.pl | 5 +-- misc/bin/clear_cache.pl | 0 misc/bin/connexion_import_daemon.pl | 14 +++--- misc/check_sysprefs.pl | 2 +- misc/commit_file.pl | 5 +-- misc/cronjobs/advance_notices.pl | 12 ++--- misc/cronjobs/archive_purchase_suggestions.pl | 4 +- misc/cronjobs/automatic_checkin.pl | 2 +- .../automatic_item_modification_by_age.pl | 10 ++--- misc/cronjobs/automatic_renewals.pl | 8 ++-- misc/cronjobs/batch_anonymise.pl | 13 ++---- misc/cronjobs/build_browser_and_cloud.pl | 10 ++--- misc/cronjobs/cart_to_shelf.pl | 7 ++- misc/cronjobs/check-url-quick.pl | 8 ++-- misc/cronjobs/cleanup_database.pl | 9 ++-- misc/cronjobs/cloud-kw.pl | 12 ++--- misc/cronjobs/create_koc_db.pl | 6 +-- misc/cronjobs/delete_items.pl | 5 +-- misc/cronjobs/delete_patrons.pl | 8 ++-- misc/cronjobs/delete_records_via_leader.pl | 8 ++-- misc/cronjobs/edi_cron.pl | 0 misc/cronjobs/fines.pl | 12 ++--- misc/cronjobs/gather_print_notices.pl | 18 ++++---- misc/cronjobs/holds/auto_unsuspend_holds.pl | 5 +-- misc/cronjobs/holds/build_holds_queue.pl | 5 +-- misc/cronjobs/holds/cancel_expired_holds.pl | 9 ++-- misc/cronjobs/holds/cancel_unfilled_holds.pl | 10 ++--- misc/cronjobs/holds/holds_reminder.pl | 14 +++--- misc/cronjobs/import_webservice_batch.pl | 6 +-- misc/cronjobs/longoverdue.pl | 10 ++--- misc/cronjobs/membership_expiry.pl | 12 +++-- misc/cronjobs/merge_authorities.pl | 6 +-- .../notice_unprocessed_suggestions.pl | 4 +- misc/cronjobs/overdue_notices.pl | 19 ++++---- misc/cronjobs/patron_emailer.pl | 9 ++-- misc/cronjobs/plugins_nightly.pl | 4 +- misc/cronjobs/process_message_queue.pl | 9 ++-- misc/cronjobs/purge_suggestions.pl | 8 ++-- misc/cronjobs/reconcile_balances.pl | 11 +++-- misc/cronjobs/remove_temporary_edifiles.pl | 0 misc/cronjobs/rss/rss.pl | 3 +- misc/cronjobs/runreport.pl | 15 +++---- misc/cronjobs/serialsUpdate.pl | 14 +++--- .../share_usage_with_koha_community.pl | 8 ++-- misc/cronjobs/sitemap.pl | 7 ++- .../social_data/get_report_social_data.pl | 0 .../social_data/update_social_data.pl | 0 misc/cronjobs/staticfines.pl | 18 ++++---- misc/cronjobs/stockrotation.pl | 0 .../thirdparty/TalkingTech_itiva_inbound.pl | 7 ++- .../thirdparty/TalkingTech_itiva_outbound.pl | 12 +++-- misc/cronjobs/update_patrons_category.pl | 9 ++-- misc/cronjobs/update_totalissues.pl | 15 +++---- misc/cronjobs/writeoff_debts.pl | 6 +-- misc/devel/add_missing_filters.pl | 6 +-- misc/devel/coverage.pl | 6 +-- misc/devel/create_superlibrarian.pl | 4 +- misc/devel/get_prepared_letter.pl | 6 +-- misc/devel/install_plugins.pl | 4 +- misc/devel/update_dbix_class_files.pl | 4 +- misc/export_borrowers.pl | 0 misc/export_records.pl | 6 +-- misc/exportauth.pl | 4 +- misc/import_patrons.pl | 6 +-- misc/kohalib.pl | 0 misc/link_bibs_to_authorities.pl | 21 +++++---- misc/load_testing/benchmark_circulation.pl | 6 +-- misc/load_testing/benchmark_staff.pl | 12 +++-- misc/load_testing/benchmark_webservices.pl | 5 +-- misc/load_yaml.pl | 2 +- .../UNIMARC_fix_collectiontitle.pl | 4 +- ...MARC_sync_date_created_with_marc_biblio.pl | 5 +-- misc/maintenance/auth_show_hidden_data.pl | 4 +- .../borrowers-force-messaging-defaults.pl | 7 ++- misc/maintenance/check_syspref_cache.pl | 4 +- misc/maintenance/cmp_sysprefs.pl | 4 +- misc/maintenance/compare_es_to_db.pl | 0 misc/maintenance/fix_accountlines_date.pl | 8 ++-- .../fix_accountlines_rmdupfines_bug8253.pl | 8 ++-- misc/maintenance/fix_mysql_constraints.pl | 9 ++-- misc/maintenance/fix_tags_weight.pl | 6 +-- misc/maintenance/generate_MARC21Languages.pl | 8 ++-- .../process_record_through_filter.pl | 1 - .../remove_items_from_biblioitems.pl | 4 +- misc/maintenance/sanitize_records.pl | 9 ++-- .../search_for_data_inconsistencies.pl | 2 +- misc/maintenance/touch_all_biblios.pl | 7 ++- misc/maintenance/touch_all_items.pl | 8 ++-- misc/maintenance/update_authorities.pl | 6 +-- .../22_to_30/convert_to_utf8.pl | 3 +- .../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 | 5 +-- .../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/buildCOUNTRY.pl | 5 +-- misc/migration_tools/buildEDITORS.pl | 6 +-- misc/migration_tools/buildLANG.pl | 5 +-- misc/migration_tools/build_oai_sets.pl | 18 +++++--- misc/migration_tools/bulkmarcimport.pl | 37 +++++++++------- .../migration_tools/checkNonIndexedBiblios.pl | 6 +-- misc/migration_tools/create_analytical_rel.pl | 6 +-- misc/migration_tools/ifla/update.pl | 10 ++--- misc/migration_tools/import_lexile.pl | 5 +-- misc/migration_tools/koha-svc.pl | 4 +- misc/migration_tools/rebuild_zebra.pl | 12 ++--- .../remove_unused_authorities.pl | 2 +- .../switch_marc21_series_info.pl | 7 ++- misc/migration_tools/upgradeitems.pl | 2 +- misc/mod_zebraqueue.pl | 4 +- misc/perlmodule_ls.pl | 0 misc/perlmodule_rm.pl | 0 misc/recreateIssueStatistics.pl | 4 +- misc/sax_parser_print.pl | 0 misc/sax_parser_test.pl | 4 +- .../export_elasticsearch_mappings.pl | 8 ++-- misc/search_tools/rebuild_elasticsearch.pl | 7 ++- misc/sip_cli_emulator.pl | 8 ++-- misc/stage_file.pl | 7 ++- misc/translator/tmpl_process3.pl | 5 +-- misc/translator/xgettext.pl | 5 +-- misc/z3950_responder.pl | 5 +-- offline_circ/download.pl | 3 +- offline_circ/enqueue_koc.pl | 4 -- offline_circ/list.pl | 2 - offline_circ/process.pl | 0 offline_circ/process_koc.pl | 7 +-- offline_circ/service.pl | 2 +- opac/clubs/clubs-tab.pl | 2 +- opac/clubs/enroll.pl | 2 +- opac/errors/400.pl | 2 +- opac/errors/401.pl | 2 +- opac/errors/402.pl | 2 +- opac/errors/403.pl | 2 +- opac/errors/404.pl | 2 +- opac/errors/500.pl | 2 +- opac/external/overdrive/auth.pl | 5 +-- opac/ilsdi.pl | 6 +-- opac/maintenance.pl | 0 opac/oai.pl | 0 opac/opac-ISBDdetail.pl | 16 +++++-- opac/opac-MARCdetail.pl | 19 +++++--- opac/opac-account-pay-return.pl | 2 +- opac/opac-account-pay.pl | 5 +-- opac/opac-account.pl | 0 opac/opac-addbybiblionumber.pl | 1 - opac/opac-alert-subscribe.pl | 2 - opac/opac-article-request-cancel.pl | 0 opac/opac-authorities-home.pl | 2 +- opac/opac-authoritiesdetail.pl | 3 +- opac/opac-basket.pl | 12 ++++- opac/opac-blocked.pl | 0 opac/opac-browse.pl | 2 +- opac/opac-browser.pl | 1 - opac/opac-changelanguage.pl | 0 opac/opac-course-details.pl | 1 - opac/opac-course-reserves.pl | 0 opac/opac-detail.pl | 44 ++++++++++++++----- opac/opac-discharge.pl | 5 +-- opac/opac-downloadcart.pl | 7 ++- opac/opac-downloadshelf.pl | 6 +-- opac/opac-export.pl | 9 +++- opac/opac-holdshistory.pl | 0 opac/opac-ics.pl | 5 +-- opac/opac-idref.pl | 9 ++-- opac/opac-illrequests.pl | 1 - opac/opac-image.pl | 0 opac/opac-imageviewer.pl | 1 - opac/opac-issue-note.pl | 5 +-- opac/opac-library.pl | 0 opac/opac-main.pl | 3 +- opac/opac-memberentry.pl | 6 +-- opac/opac-messaging.pl | 1 - opac/opac-modrequest-suspend.pl | 0 opac/opac-modrequest.pl | 0 opac/opac-mymessages.pl | 3 +- opac/opac-news-rss.pl | 5 +-- opac/opac-overdrive-search.pl | 0 opac/opac-passwd.pl | 2 +- opac/opac-password-recovery.pl | 18 +++++--- opac/opac-patron-consent.pl | 2 +- opac/opac-patron-image.pl | 0 opac/opac-privacy.pl | 0 opac/opac-ratings-ajax.pl | 3 +- opac/opac-ratings.pl | 1 - opac/opac-readingrecord.pl | 11 +++-- opac/opac-recordedbooks-search.pl | 0 opac/opac-registration-verify.pl | 2 +- opac/opac-renew.pl | 2 - opac/opac-reportproblem.pl | 8 ++-- opac/opac-request-article.pl | 0 opac/opac-reserve.pl | 12 +++-- opac/opac-restrictedpage.pl | 2 +- opac/opac-retrieve-file.pl | 3 +- opac/opac-review.pl | 6 +-- opac/opac-routing-lists.pl | 0 opac/opac-search-history.pl | 5 --- opac/opac-search.pl | 20 ++++----- opac/opac-sendbasket.pl | 17 ++++--- opac/opac-sendshelf.pl | 17 ++++--- opac/opac-serial-issues.pl | 2 - opac/opac-shareshelf.pl | 3 +- opac/opac-shelves.pl | 11 +++-- opac/opac-showmarc.pl | 3 +- opac/opac-showreviews.pl | 11 +++-- opac/opac-suggestions.pl | 4 +- opac/opac-tags.pl | 14 ++++-- opac/opac-tags_subject.pl | 1 - opac/opac-topissues.pl | 3 -- opac/opac-user.pl | 18 ++++---- opac/sci/sci-main.pl | 2 +- opac/sco/help.pl | 0 opac/sco/printslip.pl | 1 - opac/sco/sco-main.pl | 3 -- opac/sco/sco-patron-image.pl | 0 opac/svc/shelfbrowser.pl | 0 opac/tracklinks.pl | 4 +- patron_lists/add-modify.pl | 2 +- patron_lists/delete.pl | 2 +- patron_lists/list.pl | 8 +++- patron_lists/lists.pl | 2 +- patron_lists/patrons.pl | 2 +- patroncards/add_user_search.pl | 0 patroncards/create-pdf.pl | 15 +++---- patroncards/edit-batch.pl | 4 +- patroncards/edit-layout.pl | 13 ++++-- patroncards/edit-profile.pl | 2 +- patroncards/edit-template.pl | 4 +- patroncards/home.pl | 0 patroncards/image-manage.pl | 8 ++-- patroncards/manage.pl | 12 +++-- patroncards/print.pl | 3 +- plugins/plugins-enable.pl | 0 plugins/plugins-home.pl | 5 +-- plugins/plugins-uninstall.pl | 3 -- plugins/plugins-upload.pl | 5 +-- plugins/run.pl | 1 - pos/pay.pl | 2 +- pos/printreceipt.pl | 3 +- pos/register.pl | 4 +- pos/registers.pl | 2 +- reports/acquisitions_stats.pl | 4 +- reports/bor_issues_top.pl | 7 ++- reports/borrowers_out.pl | 3 +- reports/borrowers_stats.pl | 8 +--- reports/cash_register_stats.pl | 7 ++- reports/cat_issues_top.pl | 2 +- reports/catalogue_out.pl | 4 +- reports/catalogue_stats.pl | 4 +- reports/dictionary.pl | 3 +- reports/guided_reports.pl | 11 +++-- reports/issues_avg_stats.pl | 5 +-- reports/issues_stats.pl | 5 +-- reports/itemslost.pl | 5 +-- reports/manager.pl | 0 reports/orders_by_fund.pl | 4 +- reports/reports-home.pl | 0 reports/reserves_stats.pl | 6 +-- reports/serials_stats.pl | 1 - reserve/modrequest.pl | 0 reserve/modrequest_suspendall.pl | 0 reserve/placerequest.pl | 3 -- reserve/request.pl | 12 +++-- reviews/reviewswaiting.pl | 1 - rotating_collections/addItems.pl | 1 - rotating_collections/editCollections.pl | 0 rotating_collections/rotatingCollections.pl | 0 rotating_collections/transferCollection.pl | 0 serials/acqui-search-result.pl | 3 +- serials/acqui-search.pl | 0 serials/add_user_search.pl | 0 serials/checkexpiration.pl | 2 +- serials/claims.pl | 3 +- serials/create-numberpattern.pl | 6 ++- serials/lateissues-export.pl | 2 +- serials/reorder_members.pl | 0 serials/routing-preview.pl | 6 +-- serials/routing.pl | 3 +- serials/serials-collection.pl | 4 +- serials/serials-edit.pl | 11 +++-- serials/serials-home.pl | 0 serials/serials-search.pl | 3 +- serials/showpredictionpattern.pl | 4 +- serials/subscription-add.pl | 6 +-- serials/subscription-batchedit.pl | 2 +- serials/subscription-bib-search.pl | 2 +- serials/subscription-detail.pl | 6 +-- serials/subscription-frequencies.pl | 0 serials/subscription-frequency.pl | 2 +- serials/subscription-history.pl | 3 +- serials/subscription-numberpattern.pl | 2 +- serials/subscription-numberpatterns.pl | 12 ++++- serials/subscription-renew.pl | 4 +- serials/viewalerts.pl | 0 services/itemrecorddisplay.pl | 0 suggestion/add_user_search.pl | 0 suggestion/suggestion.pl | 3 +- svc/cataloguing/automatic_linker.pl | 6 +-- t/Koha/sleep.pl | 1 - t/Koha/wait.pl | 1 - t/db_dependent/LDAP/test_ldap_add.pl | 0 t/db_dependent/zebra_config.pl | 10 ++--- t/etc/schema.pl | 0 tags/list.pl | 3 +- tags/review.pl | 18 +++++--- tools/access_files.pl | 9 ++-- tools/ajax-inventory.pl | 0 tools/automatic_item_modification_by_age.pl | 5 +-- tools/background-job-progress.pl | 1 - tools/batchMod.pl | 20 ++++++--- tools/batch_delete_records.pl | 4 +- tools/batch_extend_due_dates.pl | 2 +- tools/batch_record_modification.pl | 11 ++--- tools/batch_records_ajax.pl | 3 +- tools/cleanborrowers.pl | 3 +- tools/copy-holidays.pl | 0 tools/csv-profiles.pl | 3 +- tools/exceptionHolidays.pl | 2 +- tools/export.pl | 4 +- tools/holidays.pl | 2 +- tools/import_borrowers.pl | 6 +-- tools/inventory.pl | 5 +-- tools/koha-news.pl | 13 ++++-- tools/letter.pl | 4 +- tools/manage-marc-import.pl | 1 - tools/marc_modification_templates.pl | 12 ++++- tools/modborrowers.pl | 5 +-- tools/newHolidays.pl | 2 +- tools/overduerules.pl | 3 +- tools/picture-upload.pl | 7 ++- tools/problem-reports.pl | 0 tools/quotes-upload.pl | 1 - tools/quotes.pl | 2 +- tools/scheduler.pl | 4 +- tools/showdiffmarc.pl | 0 tools/stage-marc-import.pl | 3 +- tools/stockrotation.pl | 2 +- tools/tools-home.pl | 0 tools/upload-cover-image.pl | 6 +-- tools/upload-file.pl | 6 +-- tools/upload.pl | 2 +- tools/viewlog.pl | 6 +-- virtualshelves/addbybiblionumber.pl | 1 - virtualshelves/downloadshelf.pl | 4 +- virtualshelves/sendshelf.pl | 16 ++++--- virtualshelves/shelves.pl | 9 +++- xt/author/show-template-structure.pl | 0 xt/yaml_valid.pl | 4 +- 699 files changed, 1315 insertions(+), 1469 deletions(-) mode change 100755 => 100644 about.pl mode change 100755 => 100644 acqui/acqui-home.pl mode change 100755 => 100644 acqui/add_user_search.pl mode change 100755 => 100644 acqui/addorder.pl mode change 100755 => 100644 acqui/addorderiso2709.pl mode change 100755 => 100644 acqui/ajax-getauthvaluedropbox.pl mode change 100755 => 100644 acqui/basket.pl mode change 100755 => 100644 acqui/basketgroup.pl mode change 100755 => 100644 acqui/basketheader.pl mode change 100755 => 100644 acqui/booksellers.pl mode change 100755 => 100644 acqui/cancelorder.pl mode change 100755 => 100644 acqui/check_budget_total.pl mode change 100755 => 100644 acqui/check_uniqueness.pl mode change 100755 => 100644 acqui/duplicate_orders.pl mode change 100755 => 100644 acqui/edi_ean.pl mode change 100755 => 100644 acqui/edifactmsgs.pl mode change 100755 => 100644 acqui/edimsg.pl mode change 100755 => 100644 acqui/finishreceive.pl mode change 100755 => 100644 acqui/histsearch.pl mode change 100755 => 100644 acqui/invoice-files.pl mode change 100755 => 100644 acqui/invoice.pl mode change 100755 => 100644 acqui/invoices.pl mode change 100755 => 100644 acqui/lateorders-export.pl mode change 100755 => 100644 acqui/lateorders.pl mode change 100755 => 100644 acqui/modordernotes.pl mode change 100755 => 100644 acqui/neworderempty.pl mode change 100755 => 100644 acqui/newordersubscription.pl mode change 100755 => 100644 acqui/newordersuggestion.pl mode change 100755 => 100644 acqui/ordered.pl mode change 100755 => 100644 acqui/orderreceive.pl mode change 100755 => 100644 acqui/parcel.pl mode change 100755 => 100644 acqui/parcels.pl mode change 100755 => 100644 acqui/showorder.pl mode change 100755 => 100644 acqui/spent.pl mode change 100755 => 100644 acqui/supplier.pl mode change 100755 => 100644 acqui/transferorder.pl mode change 100755 => 100644 acqui/uncertainprice.pl mode change 100755 => 100644 acqui/updatesupplier.pl mode change 100755 => 100644 acqui/z3950_search.pl mode change 100755 => 100644 admin/add_user_search.pl mode change 100755 => 100644 admin/additional-fields.pl mode change 100755 => 100644 admin/admin-home.pl mode change 100755 => 100644 admin/adveditorshortcuts.pl mode change 100755 => 100644 admin/aqbudgetperiods.pl mode change 100755 => 100644 admin/aqbudgets.pl mode change 100755 => 100644 admin/aqcontract.pl mode change 100755 => 100644 admin/aqplan.pl mode change 100755 => 100644 admin/audio_alerts.pl mode change 100755 => 100644 admin/auth_subfields_structure.pl mode change 100755 => 100644 admin/auth_tag_structure.pl mode change 100755 => 100644 admin/authorised_values.pl mode change 100755 => 100644 admin/authtypes.pl mode change 100755 => 100644 admin/background_jobs.pl mode change 100755 => 100644 admin/biblio_framework.pl mode change 100755 => 100644 admin/branch_transfer_limits.pl mode change 100755 => 100644 admin/branches.pl mode change 100755 => 100644 admin/cash_registers.pl mode change 100755 => 100644 admin/categories.pl mode change 100755 => 100644 admin/check_budget_parent.pl mode change 100755 => 100644 admin/check_parent_total.pl mode change 100755 => 100644 admin/checkmarc.pl mode change 100755 => 100644 admin/cities.pl mode change 100755 => 100644 admin/classsources.pl mode change 100755 => 100644 admin/clone-rules.pl mode change 100755 => 100644 admin/columns_settings.pl mode change 100755 => 100644 admin/credit_types.pl mode change 100755 => 100644 admin/currency.pl mode change 100755 => 100644 admin/debit_types.pl mode change 100755 => 100644 admin/desks.pl mode change 100755 => 100644 admin/didyoumean.pl mode change 100755 => 100644 admin/edi_accounts.pl mode change 100755 => 100644 admin/edi_ean_accounts.pl mode change 100755 => 100644 admin/import_export_framework.pl mode change 100755 => 100644 admin/item_circulation_alerts.pl mode change 100755 => 100644 admin/items_search_field.pl mode change 100755 => 100644 admin/items_search_fields.pl mode change 100755 => 100644 admin/itemtypes.pl mode change 100755 => 100644 admin/koha2marclinks.pl mode change 100755 => 100644 admin/library_groups.pl mode change 100755 => 100644 admin/localization.pl mode change 100755 => 100644 admin/marc_subfields_structure.pl mode change 100755 => 100644 admin/marctagstructure.pl mode change 100755 => 100644 admin/matching-rules.pl mode change 100755 => 100644 admin/oai_set_mappings.pl mode change 100755 => 100644 admin/oai_sets.pl mode change 100755 => 100644 admin/overdrive.pl mode change 100755 => 100644 admin/patron-attr-types.pl mode change 100755 => 100644 admin/preferences.pl mode change 100755 => 100644 admin/searchengine/elasticsearch/mappings.pl mode change 100755 => 100644 admin/share_content.pl mode change 100755 => 100644 admin/smart-rules.pl mode change 100755 => 100644 admin/sms_providers.pl mode change 100755 => 100644 admin/smtp_servers.pl mode change 100755 => 100644 admin/sru_modmapping.pl mode change 100755 => 100644 admin/systempreferences.pl mode change 100755 => 100644 admin/transfer_limits.pl mode change 100755 => 100644 admin/transport-cost-matrix.pl mode change 100755 => 100644 admin/usage_statistics.pl mode change 100755 => 100644 admin/z3950servers.pl mode change 100755 => 100644 api/v1/app.pl mode change 100755 => 100644 authorities/auth_finder.pl mode change 100755 => 100644 authorities/authorities-home.pl mode change 100755 => 100644 authorities/authorities.pl mode change 100755 => 100644 authorities/blinddetail-biblio-search.pl mode change 100755 => 100644 authorities/detail-biblio-search.pl mode change 100755 => 100644 authorities/detail.pl mode change 100755 => 100644 authorities/export.pl mode change 100755 => 100644 authorities/merge.pl mode change 100755 => 100644 authorities/merge_ajax.pl mode change 100755 => 100644 authorities/ysearch.pl mode change 100755 => 100644 basket/basket.pl mode change 100755 => 100644 basket/downloadcart.pl mode change 100755 => 100644 basket/sendbasket.pl mode change 100755 => 100644 catalogue/ISBDdetail.pl mode change 100755 => 100644 catalogue/MARCdetail.pl mode change 100755 => 100644 catalogue/detail.pl mode change 100755 => 100644 catalogue/export.pl mode change 100755 => 100644 catalogue/getitem-ajax.pl mode change 100755 => 100644 catalogue/image.pl mode change 100755 => 100644 catalogue/imageviewer.pl mode change 100755 => 100644 catalogue/issuehistory.pl mode change 100755 => 100644 catalogue/item-export.pl mode change 100755 => 100644 catalogue/itemsearch.pl mode change 100755 => 100644 catalogue/labeledMARCdetail.pl mode change 100755 => 100644 catalogue/moredetail.pl mode change 100755 => 100644 catalogue/search-history.pl mode change 100755 => 100644 catalogue/search.pl mode change 100755 => 100644 catalogue/showmarc.pl mode change 100755 => 100644 catalogue/stockrotation.pl mode change 100755 => 100644 catalogue/updateitem.pl mode change 100755 => 100644 cataloguing/addbiblio.pl mode change 100755 => 100644 cataloguing/addbooks.pl mode change 100755 => 100644 cataloguing/additem.pl mode change 100755 => 100644 cataloguing/editor.pl mode change 100755 => 100644 cataloguing/linkitem.pl mode change 100755 => 100644 cataloguing/merge.pl mode change 100755 => 100644 cataloguing/merge_ajax.pl mode change 100755 => 100644 cataloguing/moveitem.pl mode change 100755 => 100644 cataloguing/plugin_launcher.pl mode change 100755 => 100644 cataloguing/value_builder/EXAMPLE.pl mode change 100755 => 100644 cataloguing/value_builder/barcode.pl mode change 100755 => 100644 cataloguing/value_builder/barcode_manual.pl mode change 100755 => 100644 cataloguing/value_builder/callnumber-KU.pl mode change 100755 => 100644 cataloguing/value_builder/callnumber.pl mode change 100755 => 100644 cataloguing/value_builder/cn_browser.pl mode change 100755 => 100644 cataloguing/value_builder/dateaccessioned.pl mode change 100755 => 100644 cataloguing/value_builder/macles.pl mode change 100755 => 100644 cataloguing/value_builder/marc21_field_005.pl mode change 100755 => 100644 cataloguing/value_builder/marc21_field_006.pl mode change 100755 => 100644 cataloguing/value_builder/marc21_field_007.pl mode change 100755 => 100644 cataloguing/value_builder/marc21_field_008.pl mode change 100755 => 100644 cataloguing/value_builder/marc21_field_008_authorities.pl mode change 100755 => 100644 cataloguing/value_builder/marc21_field_008_classifications.pl mode change 100755 => 100644 cataloguing/value_builder/marc21_field_245h.pl mode change 100755 => 100644 cataloguing/value_builder/marc21_field_260b.pl mode change 100755 => 100644 cataloguing/value_builder/marc21_leader.pl mode change 100755 => 100644 cataloguing/value_builder/marc21_leader_authorities.pl mode change 100755 => 100644 cataloguing/value_builder/marc21_linking_section.pl mode change 100755 => 100644 cataloguing/value_builder/marc21_orgcode.pl mode change 100755 => 100644 cataloguing/value_builder/normarc_field_007.pl mode change 100755 => 100644 cataloguing/value_builder/normarc_field_008.pl mode change 100755 => 100644 cataloguing/value_builder/normarc_leader.pl mode change 100755 => 100644 cataloguing/value_builder/stocknumber.pl mode change 100755 => 100644 cataloguing/value_builder/stocknumberAV.pl mode change 100755 => 100644 cataloguing/value_builder/stocknumberam123.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_010.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_100.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_100_authorities.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_105.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_106.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_110.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_115a.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_115b.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_116.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_117.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_120.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_121a.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_121b.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_122.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_123a.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_123d.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_123e.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_123f.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_123g.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_123i.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_123j.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_124.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_124a.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_124b.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_124c.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_124d.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_124e.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_124f.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_124g.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_125.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_125a.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_125b.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_126.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_126a.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_126b.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_127.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_128a.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_128b.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_128c.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_130.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_135a.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_140.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_141.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_210c.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_210c_bis.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_225a.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_225a_bis.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_4XX.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_686a.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_field_700-4.pl mode change 100755 => 100644 cataloguing/value_builder/unimarc_leader.pl mode change 100755 => 100644 cataloguing/value_builder/upload.pl mode change 100755 => 100644 cataloguing/ysearch.pl mode change 100755 => 100644 cataloguing/z3950_auth_search.pl mode change 100755 => 100644 cataloguing/z3950_search.pl mode change 100755 => 100644 changelanguage.pl mode change 100755 => 100644 circ/add_message.pl mode change 100755 => 100644 circ/article-request-slip.pl mode change 100755 => 100644 circ/article-requests.pl mode change 100755 => 100644 circ/bookcount.pl mode change 100755 => 100644 circ/branchoverdues.pl mode change 100755 => 100644 circ/branchtransfers.pl mode change 100755 => 100644 circ/checkout-notes.pl mode change 100755 => 100644 circ/circulation-home.pl mode change 100755 => 100644 circ/circulation.pl mode change 100755 => 100644 circ/del_message.pl mode change 100755 => 100644 circ/hold-transfer-slip.pl mode change 100755 => 100644 circ/offline-mf.pl mode change 100755 => 100644 circ/offline.pl mode change 100755 => 100644 circ/on-site_checkouts.pl mode change 100755 => 100644 circ/overdue.pl mode change 100755 => 100644 circ/pendingreserves.pl mode change 100755 => 100644 circ/renew.pl mode change 100755 => 100644 circ/request-article.pl mode change 100755 => 100644 circ/reserveratios.pl mode change 100755 => 100644 circ/returns.pl mode change 100755 => 100644 circ/set-library.pl mode change 100755 => 100644 circ/transfer-slip.pl mode change 100755 => 100644 circ/transfers_to_send.pl mode change 100755 => 100644 circ/transferstoreceive.pl mode change 100755 => 100644 circ/view_holdsqueue.pl mode change 100755 => 100644 circ/waitingreserves.pl mode change 100755 => 100644 circ/ysearch.pl mode change 100755 => 100644 clubs/club-enrollments.pl mode change 100755 => 100644 clubs/clubs-add-modify.pl mode change 100755 => 100644 clubs/clubs.pl mode change 100755 => 100644 clubs/patron-clubs-tab.pl mode change 100755 => 100644 clubs/patron-enroll.pl mode change 100755 => 100644 clubs/templates-add-modify.pl mode change 100755 => 100644 course_reserves/add_items.pl mode change 100755 => 100644 course_reserves/batch_add_items.pl mode change 100755 => 100644 course_reserves/batch_rm_items.pl mode change 100755 => 100644 course_reserves/course-details.pl mode change 100755 => 100644 course_reserves/course-reserves.pl mode change 100755 => 100644 course_reserves/course.pl mode change 100755 => 100644 course_reserves/mod_course.pl mode change 100755 => 100644 docs/CAS/CASProxy/examples/koha_webservice.pl mode change 100755 => 100644 docs/CAS/CASProxy/examples/proxy_cas.pl mode change 100755 => 100644 docs/CAS/CASProxy/examples/proxy_cas_callback.pl mode change 100755 => 100644 docs/CAS/CASProxy/examples/proxy_cas_data.pl mode change 100755 => 100644 errors/400.pl mode change 100755 => 100644 errors/401.pl mode change 100755 => 100644 errors/402.pl mode change 100755 => 100644 errors/403.pl mode change 100755 => 100644 errors/404.pl mode change 100755 => 100644 errors/500.pl mode change 100755 => 100644 help.pl mode change 100755 => 100644 ill/ill-requests.pl mode change 100755 => 100644 installer/data/mysql/backfill_statistics.pl mode change 100755 => 100644 installer/data/mysql/fix_unclosed_nonaccruing_fines_bug17135.pl mode change 100755 => 100644 installer/data/mysql/labels_upgrade.pl mode change 100755 => 100644 installer/data/mysql/patroncards_upgrade.pl mode change 100755 => 100644 installer/data/mysql/update22to30.pl mode change 100755 => 100644 installer/data/mysql/updatedatabase.pl mode change 100755 => 100644 installer/externalmodules.pl mode change 100755 => 100644 installer/html-template-to-template-toolkit.pl mode change 100755 => 100644 installer/install.pl mode change 100755 => 100644 installer/onboarding.pl mode change 100755 => 100644 koha_perl_deps.pl mode change 100755 => 100644 kohaversion.pl mode change 100755 => 100644 labels/label-create-csv.pl mode change 100755 => 100644 labels/label-create-pdf.pl mode change 100755 => 100644 labels/label-create-xml.pl mode change 100755 => 100644 labels/label-edit-batch.pl mode change 100755 => 100644 labels/label-edit-layout.pl mode change 100755 => 100644 labels/label-edit-profile.pl mode change 100755 => 100644 labels/label-edit-range.pl mode change 100755 => 100644 labels/label-edit-template.pl mode change 100755 => 100644 labels/label-home.pl mode change 100755 => 100644 labels/label-item-search.pl mode change 100755 => 100644 labels/label-manage.pl mode change 100755 => 100644 labels/label-print.pl mode change 100755 => 100644 labels/spinelabel-home.pl mode change 100755 => 100644 labels/spinelabel-print.pl mode change 100755 => 100644 mainpage.pl mode change 100755 => 100644 members/accountline-details.pl mode change 100755 => 100644 members/apikeys.pl mode change 100755 => 100644 members/boraccount.pl mode change 100755 => 100644 members/cancel-charge.pl mode change 100755 => 100644 members/default_messageprefs.pl mode change 100755 => 100644 members/deletemem.pl mode change 100755 => 100644 members/discharge.pl mode change 100755 => 100644 members/discharges.pl mode change 100755 => 100644 members/files.pl mode change 100755 => 100644 members/guarantor_search.pl mode change 100755 => 100644 members/holdshistory.pl mode change 100755 => 100644 members/housebound.pl mode change 100755 => 100644 members/ill-requests.pl mode change 100755 => 100644 members/mancredit.pl mode change 100755 => 100644 members/maninvoice.pl mode change 100755 => 100644 members/member-flags.pl mode change 100755 => 100644 members/member-password.pl mode change 100755 => 100644 members/member.pl mode change 100755 => 100644 members/memberentry.pl mode change 100755 => 100644 members/members-home.pl mode change 100755 => 100644 members/members-update-do.pl mode change 100755 => 100644 members/members-update.pl mode change 100755 => 100644 members/merge-patrons.pl mode change 100755 => 100644 members/mod_debarment.pl mode change 100755 => 100644 members/moremember.pl mode change 100755 => 100644 members/notices.pl mode change 100755 => 100644 members/patronimage.pl mode change 100755 => 100644 members/pay.pl mode change 100755 => 100644 members/paycollect.pl mode change 100755 => 100644 members/print_overdues.pl mode change 100755 => 100644 members/printfeercpt.pl mode change 100755 => 100644 members/printinvoice.pl mode change 100755 => 100644 members/printslip.pl mode change 100755 => 100644 members/purchase-suggestions.pl mode change 100755 => 100644 members/readingrec.pl mode change 100755 => 100644 members/routing-lists.pl mode change 100755 => 100644 members/setstatus.pl mode change 100755 => 100644 members/statistics.pl mode change 100755 => 100644 members/summary-print.pl mode change 100755 => 100644 members/update-child.pl mode change 100755 => 100644 misc/add_date_fields_to_marc_records.pl mode change 100755 => 100644 misc/admin/set_password.pl mode change 100755 => 100644 misc/background_jobs_worker.pl mode change 100755 => 100644 misc/batchCompareMARCvsFrameworks.pl mode change 100755 => 100644 misc/batchDeleteUnusedSubfields.pl mode change 100755 => 100644 misc/batchImportMARCWithBiblionumbers.pl mode change 100755 => 100644 misc/batchRebuildBiblioTables.pl mode change 100755 => 100644 misc/batchRebuildItemsTables.pl mode change 100755 => 100644 misc/batchRepairMissingBiblionumbers.pl mode change 100755 => 100644 misc/batchdeletebiblios.pl mode change 100755 => 100644 misc/bin/clear_cache.pl mode change 100755 => 100644 misc/bin/connexion_import_daemon.pl mode change 100755 => 100644 misc/check_sysprefs.pl mode change 100755 => 100644 misc/commit_file.pl mode change 100755 => 100644 misc/cronjobs/advance_notices.pl mode change 100755 => 100644 misc/cronjobs/archive_purchase_suggestions.pl mode change 100755 => 100644 misc/cronjobs/automatic_checkin.pl mode change 100755 => 100644 misc/cronjobs/automatic_item_modification_by_age.pl mode change 100755 => 100644 misc/cronjobs/automatic_renewals.pl mode change 100755 => 100644 misc/cronjobs/batch_anonymise.pl mode change 100755 => 100644 misc/cronjobs/build_browser_and_cloud.pl mode change 100755 => 100644 misc/cronjobs/cart_to_shelf.pl mode change 100755 => 100644 misc/cronjobs/check-url-quick.pl mode change 100755 => 100644 misc/cronjobs/cleanup_database.pl mode change 100755 => 100644 misc/cronjobs/cloud-kw.pl mode change 100755 => 100644 misc/cronjobs/create_koc_db.pl mode change 100755 => 100644 misc/cronjobs/delete_items.pl mode change 100755 => 100644 misc/cronjobs/delete_patrons.pl mode change 100755 => 100644 misc/cronjobs/delete_records_via_leader.pl mode change 100755 => 100644 misc/cronjobs/edi_cron.pl mode change 100755 => 100644 misc/cronjobs/fines.pl mode change 100755 => 100644 misc/cronjobs/gather_print_notices.pl mode change 100755 => 100644 misc/cronjobs/holds/auto_unsuspend_holds.pl mode change 100755 => 100644 misc/cronjobs/holds/build_holds_queue.pl mode change 100755 => 100644 misc/cronjobs/holds/cancel_expired_holds.pl mode change 100755 => 100644 misc/cronjobs/holds/cancel_unfilled_holds.pl mode change 100755 => 100644 misc/cronjobs/holds/holds_reminder.pl mode change 100755 => 100644 misc/cronjobs/import_webservice_batch.pl mode change 100755 => 100644 misc/cronjobs/longoverdue.pl mode change 100755 => 100644 misc/cronjobs/membership_expiry.pl mode change 100755 => 100644 misc/cronjobs/merge_authorities.pl mode change 100755 => 100644 misc/cronjobs/notice_unprocessed_suggestions.pl mode change 100755 => 100644 misc/cronjobs/overdue_notices.pl mode change 100755 => 100644 misc/cronjobs/patron_emailer.pl mode change 100755 => 100644 misc/cronjobs/plugins_nightly.pl mode change 100755 => 100644 misc/cronjobs/process_message_queue.pl mode change 100755 => 100644 misc/cronjobs/purge_suggestions.pl mode change 100755 => 100644 misc/cronjobs/reconcile_balances.pl mode change 100755 => 100644 misc/cronjobs/remove_temporary_edifiles.pl mode change 100755 => 100644 misc/cronjobs/rss/rss.pl mode change 100755 => 100644 misc/cronjobs/runreport.pl mode change 100755 => 100644 misc/cronjobs/serialsUpdate.pl mode change 100755 => 100644 misc/cronjobs/share_usage_with_koha_community.pl mode change 100755 => 100644 misc/cronjobs/sitemap.pl mode change 100755 => 100644 misc/cronjobs/social_data/get_report_social_data.pl mode change 100755 => 100644 misc/cronjobs/social_data/update_social_data.pl mode change 100755 => 100644 misc/cronjobs/staticfines.pl mode change 100755 => 100644 misc/cronjobs/stockrotation.pl mode change 100755 => 100644 misc/cronjobs/thirdparty/TalkingTech_itiva_inbound.pl mode change 100755 => 100644 misc/cronjobs/thirdparty/TalkingTech_itiva_outbound.pl mode change 100755 => 100644 misc/cronjobs/update_patrons_category.pl mode change 100755 => 100644 misc/cronjobs/update_totalissues.pl mode change 100755 => 100644 misc/cronjobs/writeoff_debts.pl mode change 100755 => 100644 misc/devel/add_missing_filters.pl mode change 100755 => 100644 misc/devel/coverage.pl mode change 100755 => 100644 misc/devel/create_superlibrarian.pl mode change 100755 => 100644 misc/devel/get_prepared_letter.pl mode change 100755 => 100644 misc/devel/install_plugins.pl mode change 100755 => 100644 misc/devel/update_dbix_class_files.pl mode change 100755 => 100644 misc/export_borrowers.pl mode change 100755 => 100644 misc/export_records.pl mode change 100755 => 100644 misc/exportauth.pl mode change 100755 => 100644 misc/import_patrons.pl mode change 100755 => 100644 misc/kohalib.pl mode change 100755 => 100644 misc/link_bibs_to_authorities.pl mode change 100755 => 100644 misc/load_testing/benchmark_circulation.pl mode change 100755 => 100644 misc/load_testing/benchmark_staff.pl mode change 100755 => 100644 misc/load_testing/benchmark_webservices.pl mode change 100755 => 100644 misc/load_yaml.pl mode change 100755 => 100644 misc/maintenance/UNIMARC_fix_collectiontitle.pl mode change 100755 => 100644 misc/maintenance/UNIMARC_sync_date_created_with_marc_biblio.pl mode change 100755 => 100644 misc/maintenance/auth_show_hidden_data.pl mode change 100755 => 100644 misc/maintenance/borrowers-force-messaging-defaults.pl mode change 100755 => 100644 misc/maintenance/check_syspref_cache.pl mode change 100755 => 100644 misc/maintenance/cmp_sysprefs.pl mode change 100755 => 100644 misc/maintenance/compare_es_to_db.pl mode change 100755 => 100644 misc/maintenance/fix_accountlines_date.pl mode change 100755 => 100644 misc/maintenance/fix_accountlines_rmdupfines_bug8253.pl mode change 100755 => 100644 misc/maintenance/fix_mysql_constraints.pl mode change 100755 => 100644 misc/maintenance/fix_tags_weight.pl mode change 100755 => 100644 misc/maintenance/generate_MARC21Languages.pl mode change 100755 => 100644 misc/maintenance/process_record_through_filter.pl mode change 100755 => 100644 misc/maintenance/remove_items_from_biblioitems.pl mode change 100755 => 100644 misc/maintenance/sanitize_records.pl mode change 100755 => 100644 misc/maintenance/search_for_data_inconsistencies.pl mode change 100755 => 100644 misc/maintenance/touch_all_biblios.pl mode change 100755 => 100644 misc/maintenance/touch_all_items.pl mode change 100755 => 100644 misc/maintenance/update_authorities.pl mode change 100755 => 100644 misc/migration_tools/22_to_30/convert_to_utf8.pl mode change 100755 => 100644 misc/migration_tools/22_to_30/export_Authorities.pl mode change 100755 => 100644 misc/migration_tools/22_to_30/export_Authorities_xml.pl mode change 100755 => 100644 misc/migration_tools/22_to_30/missing090field.pl mode change 100755 => 100644 misc/migration_tools/22_to_30/move_marc_to_authheader.pl mode change 100755 => 100644 misc/migration_tools/22_to_30/move_marc_to_biblioitems.pl mode change 100755 => 100644 misc/migration_tools/22_to_30/rebuild_leader.pl mode change 100755 => 100644 misc/migration_tools/22_to_30/rebuild_unimarc_100.pl mode change 100755 => 100644 misc/migration_tools/buildCOUNTRY.pl mode change 100755 => 100644 misc/migration_tools/buildEDITORS.pl mode change 100755 => 100644 misc/migration_tools/buildLANG.pl mode change 100755 => 100644 misc/migration_tools/build_oai_sets.pl mode change 100755 => 100644 misc/migration_tools/bulkmarcimport.pl mode change 100755 => 100644 misc/migration_tools/checkNonIndexedBiblios.pl mode change 100755 => 100644 misc/migration_tools/create_analytical_rel.pl mode change 100755 => 100644 misc/migration_tools/ifla/update.pl mode change 100755 => 100644 misc/migration_tools/import_lexile.pl mode change 100755 => 100644 misc/migration_tools/koha-svc.pl mode change 100755 => 100644 misc/migration_tools/rebuild_zebra.pl mode change 100755 => 100644 misc/migration_tools/remove_unused_authorities.pl mode change 100755 => 100644 misc/migration_tools/switch_marc21_series_info.pl mode change 100755 => 100644 misc/migration_tools/upgradeitems.pl mode change 100755 => 100644 misc/mod_zebraqueue.pl mode change 100755 => 100644 misc/perlmodule_ls.pl mode change 100755 => 100644 misc/perlmodule_rm.pl mode change 100755 => 100644 misc/recreateIssueStatistics.pl mode change 100755 => 100644 misc/sax_parser_print.pl mode change 100755 => 100644 misc/sax_parser_test.pl mode change 100755 => 100644 misc/search_tools/export_elasticsearch_mappings.pl mode change 100755 => 100644 misc/search_tools/rebuild_elasticsearch.pl mode change 100755 => 100644 misc/sip_cli_emulator.pl mode change 100755 => 100644 misc/stage_file.pl mode change 100755 => 100644 misc/translator/tmpl_process3.pl mode change 100755 => 100644 misc/translator/xgettext.pl mode change 100755 => 100644 misc/z3950_responder.pl mode change 100755 => 100644 offline_circ/download.pl mode change 100755 => 100644 offline_circ/enqueue_koc.pl mode change 100755 => 100644 offline_circ/list.pl mode change 100755 => 100644 offline_circ/process.pl mode change 100755 => 100644 offline_circ/process_koc.pl mode change 100755 => 100644 offline_circ/service.pl mode change 100755 => 100644 opac/clubs/clubs-tab.pl mode change 100755 => 100644 opac/clubs/enroll.pl mode change 100755 => 100644 opac/errors/400.pl mode change 100755 => 100644 opac/errors/401.pl mode change 100755 => 100644 opac/errors/402.pl mode change 100755 => 100644 opac/errors/403.pl mode change 100755 => 100644 opac/errors/404.pl mode change 100755 => 100644 opac/errors/500.pl mode change 100755 => 100644 opac/external/overdrive/auth.pl mode change 100755 => 100644 opac/ilsdi.pl mode change 100755 => 100644 opac/maintenance.pl mode change 100755 => 100644 opac/oai.pl mode change 100755 => 100644 opac/opac-ISBDdetail.pl mode change 100755 => 100644 opac/opac-MARCdetail.pl mode change 100755 => 100644 opac/opac-account-pay-return.pl mode change 100755 => 100644 opac/opac-account-pay.pl mode change 100755 => 100644 opac/opac-account.pl mode change 100755 => 100644 opac/opac-addbybiblionumber.pl mode change 100755 => 100644 opac/opac-alert-subscribe.pl mode change 100755 => 100644 opac/opac-article-request-cancel.pl mode change 100755 => 100644 opac/opac-authorities-home.pl mode change 100755 => 100644 opac/opac-authoritiesdetail.pl mode change 100755 => 100644 opac/opac-basket.pl mode change 100755 => 100644 opac/opac-blocked.pl mode change 100755 => 100644 opac/opac-browse.pl mode change 100755 => 100644 opac/opac-browser.pl mode change 100755 => 100644 opac/opac-changelanguage.pl mode change 100755 => 100644 opac/opac-course-details.pl mode change 100755 => 100644 opac/opac-course-reserves.pl mode change 100755 => 100644 opac/opac-detail.pl mode change 100755 => 100644 opac/opac-discharge.pl mode change 100755 => 100644 opac/opac-downloadcart.pl mode change 100755 => 100644 opac/opac-downloadshelf.pl mode change 100755 => 100644 opac/opac-export.pl mode change 100755 => 100644 opac/opac-holdshistory.pl mode change 100755 => 100644 opac/opac-ics.pl mode change 100755 => 100644 opac/opac-idref.pl mode change 100755 => 100644 opac/opac-illrequests.pl mode change 100755 => 100644 opac/opac-image.pl mode change 100755 => 100644 opac/opac-imageviewer.pl mode change 100755 => 100644 opac/opac-issue-note.pl mode change 100755 => 100644 opac/opac-library.pl mode change 100755 => 100644 opac/opac-main.pl mode change 100755 => 100644 opac/opac-memberentry.pl mode change 100755 => 100644 opac/opac-messaging.pl mode change 100755 => 100644 opac/opac-modrequest-suspend.pl mode change 100755 => 100644 opac/opac-modrequest.pl mode change 100755 => 100644 opac/opac-mymessages.pl mode change 100755 => 100644 opac/opac-news-rss.pl mode change 100755 => 100644 opac/opac-overdrive-search.pl mode change 100755 => 100644 opac/opac-passwd.pl mode change 100755 => 100644 opac/opac-password-recovery.pl mode change 100755 => 100644 opac/opac-patron-consent.pl mode change 100755 => 100644 opac/opac-patron-image.pl mode change 100755 => 100644 opac/opac-privacy.pl mode change 100755 => 100644 opac/opac-ratings-ajax.pl mode change 100755 => 100644 opac/opac-ratings.pl mode change 100755 => 100644 opac/opac-readingrecord.pl mode change 100755 => 100644 opac/opac-recordedbooks-search.pl mode change 100755 => 100644 opac/opac-registration-verify.pl mode change 100755 => 100644 opac/opac-renew.pl mode change 100755 => 100644 opac/opac-reportproblem.pl mode change 100755 => 100644 opac/opac-request-article.pl mode change 100755 => 100644 opac/opac-reserve.pl mode change 100755 => 100644 opac/opac-restrictedpage.pl mode change 100755 => 100644 opac/opac-retrieve-file.pl mode change 100755 => 100644 opac/opac-review.pl mode change 100755 => 100644 opac/opac-routing-lists.pl mode change 100755 => 100644 opac/opac-search-history.pl mode change 100755 => 100644 opac/opac-search.pl mode change 100755 => 100644 opac/opac-sendbasket.pl mode change 100755 => 100644 opac/opac-sendshelf.pl mode change 100755 => 100644 opac/opac-serial-issues.pl mode change 100755 => 100644 opac/opac-shareshelf.pl mode change 100755 => 100644 opac/opac-shelves.pl mode change 100755 => 100644 opac/opac-showmarc.pl mode change 100755 => 100644 opac/opac-showreviews.pl mode change 100755 => 100644 opac/opac-suggestions.pl mode change 100755 => 100644 opac/opac-tags.pl mode change 100755 => 100644 opac/opac-tags_subject.pl mode change 100755 => 100644 opac/opac-topissues.pl mode change 100755 => 100644 opac/opac-user.pl mode change 100755 => 100644 opac/sci/sci-main.pl mode change 100755 => 100644 opac/sco/help.pl mode change 100755 => 100644 opac/sco/printslip.pl mode change 100755 => 100644 opac/sco/sco-main.pl mode change 100755 => 100644 opac/sco/sco-patron-image.pl mode change 100755 => 100644 opac/svc/shelfbrowser.pl mode change 100755 => 100644 opac/tracklinks.pl mode change 100755 => 100644 patron_lists/add-modify.pl mode change 100755 => 100644 patron_lists/delete.pl mode change 100755 => 100644 patron_lists/list.pl mode change 100755 => 100644 patron_lists/lists.pl mode change 100755 => 100644 patron_lists/patrons.pl mode change 100755 => 100644 patroncards/add_user_search.pl mode change 100755 => 100644 patroncards/create-pdf.pl mode change 100755 => 100644 patroncards/edit-batch.pl mode change 100755 => 100644 patroncards/edit-layout.pl mode change 100755 => 100644 patroncards/edit-profile.pl mode change 100755 => 100644 patroncards/edit-template.pl mode change 100755 => 100644 patroncards/home.pl mode change 100755 => 100644 patroncards/image-manage.pl mode change 100755 => 100644 patroncards/manage.pl mode change 100755 => 100644 patroncards/print.pl mode change 100755 => 100644 plugins/plugins-enable.pl mode change 100755 => 100644 plugins/plugins-home.pl mode change 100755 => 100644 plugins/plugins-uninstall.pl mode change 100755 => 100644 plugins/plugins-upload.pl mode change 100755 => 100644 plugins/run.pl mode change 100755 => 100644 pos/pay.pl mode change 100755 => 100644 pos/printreceipt.pl mode change 100755 => 100644 pos/register.pl mode change 100755 => 100644 pos/registers.pl mode change 100755 => 100644 reports/acquisitions_stats.pl mode change 100755 => 100644 reports/bor_issues_top.pl mode change 100755 => 100644 reports/borrowers_out.pl mode change 100755 => 100644 reports/borrowers_stats.pl mode change 100755 => 100644 reports/cash_register_stats.pl mode change 100755 => 100644 reports/cat_issues_top.pl mode change 100755 => 100644 reports/catalogue_out.pl mode change 100755 => 100644 reports/catalogue_stats.pl mode change 100755 => 100644 reports/dictionary.pl mode change 100755 => 100644 reports/guided_reports.pl mode change 100755 => 100644 reports/issues_avg_stats.pl mode change 100755 => 100644 reports/issues_stats.pl mode change 100755 => 100644 reports/itemslost.pl mode change 100755 => 100644 reports/manager.pl mode change 100755 => 100644 reports/orders_by_fund.pl mode change 100755 => 100644 reports/reports-home.pl mode change 100755 => 100644 reports/reserves_stats.pl mode change 100755 => 100644 reports/serials_stats.pl mode change 100755 => 100644 reserve/modrequest.pl mode change 100755 => 100644 reserve/modrequest_suspendall.pl mode change 100755 => 100644 reserve/placerequest.pl mode change 100755 => 100644 reserve/request.pl mode change 100755 => 100644 reviews/reviewswaiting.pl mode change 100755 => 100644 rotating_collections/addItems.pl mode change 100755 => 100644 rotating_collections/editCollections.pl mode change 100755 => 100644 rotating_collections/rotatingCollections.pl mode change 100755 => 100644 rotating_collections/transferCollection.pl mode change 100755 => 100644 serials/acqui-search-result.pl mode change 100755 => 100644 serials/acqui-search.pl mode change 100755 => 100644 serials/add_user_search.pl mode change 100755 => 100644 serials/checkexpiration.pl mode change 100755 => 100644 serials/claims.pl mode change 100755 => 100644 serials/create-numberpattern.pl mode change 100755 => 100644 serials/lateissues-export.pl mode change 100755 => 100644 serials/reorder_members.pl mode change 100755 => 100644 serials/routing-preview.pl mode change 100755 => 100644 serials/routing.pl mode change 100755 => 100644 serials/serials-collection.pl mode change 100755 => 100644 serials/serials-edit.pl mode change 100755 => 100644 serials/serials-home.pl mode change 100755 => 100644 serials/serials-search.pl mode change 100755 => 100644 serials/showpredictionpattern.pl mode change 100755 => 100644 serials/subscription-add.pl mode change 100755 => 100644 serials/subscription-batchedit.pl mode change 100755 => 100644 serials/subscription-bib-search.pl mode change 100755 => 100644 serials/subscription-detail.pl mode change 100755 => 100644 serials/subscription-frequencies.pl mode change 100755 => 100644 serials/subscription-frequency.pl mode change 100755 => 100644 serials/subscription-history.pl mode change 100755 => 100644 serials/subscription-numberpattern.pl mode change 100755 => 100644 serials/subscription-numberpatterns.pl mode change 100755 => 100644 serials/subscription-renew.pl mode change 100755 => 100644 serials/viewalerts.pl mode change 100755 => 100644 services/itemrecorddisplay.pl mode change 100755 => 100644 suggestion/add_user_search.pl mode change 100755 => 100644 suggestion/suggestion.pl mode change 100755 => 100644 svc/cataloguing/automatic_linker.pl mode change 100755 => 100644 t/Koha/sleep.pl mode change 100755 => 100644 t/Koha/wait.pl mode change 100755 => 100644 t/db_dependent/LDAP/test_ldap_add.pl mode change 100755 => 100644 t/db_dependent/zebra_config.pl mode change 100755 => 100644 t/etc/schema.pl mode change 100755 => 100644 tags/list.pl mode change 100755 => 100644 tags/review.pl mode change 100755 => 100644 tools/access_files.pl mode change 100755 => 100644 tools/ajax-inventory.pl mode change 100755 => 100644 tools/automatic_item_modification_by_age.pl mode change 100755 => 100644 tools/background-job-progress.pl mode change 100755 => 100644 tools/batchMod.pl mode change 100755 => 100644 tools/batch_delete_records.pl mode change 100755 => 100644 tools/batch_extend_due_dates.pl mode change 100755 => 100644 tools/batch_record_modification.pl mode change 100755 => 100644 tools/batch_records_ajax.pl mode change 100755 => 100644 tools/cleanborrowers.pl mode change 100755 => 100644 tools/copy-holidays.pl mode change 100755 => 100644 tools/csv-profiles.pl mode change 100755 => 100644 tools/exceptionHolidays.pl mode change 100755 => 100644 tools/export.pl mode change 100755 => 100644 tools/holidays.pl mode change 100755 => 100644 tools/import_borrowers.pl mode change 100755 => 100644 tools/inventory.pl mode change 100755 => 100644 tools/koha-news.pl mode change 100755 => 100644 tools/letter.pl mode change 100755 => 100644 tools/manage-marc-import.pl mode change 100755 => 100644 tools/marc_modification_templates.pl mode change 100755 => 100644 tools/modborrowers.pl mode change 100755 => 100644 tools/newHolidays.pl mode change 100755 => 100644 tools/overduerules.pl mode change 100755 => 100644 tools/picture-upload.pl mode change 100755 => 100644 tools/problem-reports.pl mode change 100755 => 100644 tools/quotes-upload.pl mode change 100755 => 100644 tools/quotes.pl mode change 100755 => 100644 tools/scheduler.pl mode change 100755 => 100644 tools/showdiffmarc.pl mode change 100755 => 100644 tools/stage-marc-import.pl mode change 100755 => 100644 tools/stockrotation.pl mode change 100755 => 100644 tools/tools-home.pl mode change 100755 => 100644 tools/upload-cover-image.pl mode change 100755 => 100644 tools/upload-file.pl mode change 100755 => 100644 tools/upload.pl mode change 100755 => 100644 tools/viewlog.pl mode change 100755 => 100644 virtualshelves/addbybiblionumber.pl mode change 100755 => 100644 virtualshelves/downloadshelf.pl mode change 100755 => 100644 virtualshelves/sendshelf.pl mode change 100755 => 100644 virtualshelves/shelves.pl mode change 100755 => 100644 xt/author/show-template-structure.pl mode change 100755 => 100644 xt/yaml_valid.pl diff --git a/about.pl b/about.pl old mode 100755 new mode 100644 index 0e9eed8931b..790b146d634 --- a/about.pl +++ b/about.pl @@ -24,17 +24,14 @@ use Modern::Perl; use CGI qw ( -utf8 ); use DateTime::TimeZone; -use File::Spec; -use File::Slurp; -use List::MoreUtils qw/ any /; -use LWP::Simple; -use Module::Load::Conditional qw(can_load); -use XML::Simple; -use Config; +use File::Slurp qw( read_file ); +use List::MoreUtils qw( any ); +use Module::Load::Conditional qw( can_load ); +use Config qw( %Config ); use Search::Elasticsearch; -use Try::Tiny; -use YAML::XS; -use Encode; +use Try::Tiny qw( catch try ); +use YAML::XS (); +use Encode (); use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user get_user_subpermissions ); @@ -42,7 +39,7 @@ use C4::Context; use C4::Installer::PerlModules; use Koha; -use Koha::DateUtils qw(dt_from_string output_pref); +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Acquisition::Currencies; use Koha::BackgroundJob; use Koha::BiblioFrameworks; @@ -56,7 +53,7 @@ use Koha::SearchEngine::Elasticsearch; use Koha::Logger; use Koha::Filter::MARC::ViewPolicy; -use C4::Members::Statistics qw( get_fields ); +use C4::Members::Statistics (); #use Smart::Comments '####'; diff --git a/acqui/acqui-home.pl b/acqui/acqui-home.pl old mode 100755 new mode 100644 index 00e4699ec53..c73c29bfc4f --- a/acqui/acqui-home.pl +++ b/acqui/acqui-home.pl @@ -34,7 +34,6 @@ use C4::Output qw( output_html_with_http_headers ); use C4::Acquisition; use C4::Budgets; use C4::Members; -use C4::Debug; use Koha::Acquisition::Currencies; use Koha::Patrons; use Koha::Suggestions; diff --git a/acqui/add_user_search.pl b/acqui/add_user_search.pl old mode 100755 new mode 100644 diff --git a/acqui/addorder.pl b/acqui/addorder.pl old mode 100755 new mode 100644 index 8aeae1bb3f9..8d1d3cb2901 --- a/acqui/addorder.pl +++ b/acqui/addorder.pl @@ -119,15 +119,20 @@ if it is an order from an existing suggestion : the id of this suggestion. use Modern::Perl; use CGI qw ( -utf8 ); -use JSON qw ( to_json ); +use JSON qw( to_json ); use C4::Auth qw( get_template_and_user ); use C4::Acquisition; # ModOrder use C4::Suggestions; # ModStatus -use C4::Biblio qw( TransformHtmlToXml TransformKohaToMarc AddBiblio GetMarcFromKohaField ); +use C4::Biblio qw( + AddBiblio + GetMarcFromKohaField + TransformHtmlToXml + TransformKohaToMarc +); use C4::Budgets; -use C4::Items qw( sub AddItemFromMarc ); +use C4::Items qw( AddItemFromMarc ); use C4::Output qw( output_html_with_http_headers ); -use C4::Log qw(logaction); +use C4::Log qw( logaction ); use Koha::Acquisition::Currencies; use Koha::Acquisition::Orders; use Koha::Acquisition::Baskets; diff --git a/acqui/addorderiso2709.pl b/acqui/addorderiso2709.pl old mode 100755 new mode 100644 index 5f4e65534e9..62f6a08e762 --- a/acqui/addorderiso2709.pl +++ b/acqui/addorderiso2709.pl @@ -23,10 +23,9 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Carp; -use YAML::XS; -use List::MoreUtils qw/uniq/; -use Encode; +use YAML::XS (); +use List::MoreUtils (); +use Encode (); use C4::Context; use C4::Auth qw( get_template_and_user ); @@ -35,9 +34,14 @@ use C4::ImportBatch qw( GetImportRecordsRange GetImportRecordMarc GetImportRecor use C4::Matcher; use C4::Search qw( FindDuplicate ); use C4::Acquisition; -use C4::Biblio qw( GetMarcQuantity GetMarcFromKohaField AddBiblio GetMarcPrice TransformHtmlToXml ); -use C4::Items qw( PrepareItemrecordDisplay sub AddItemFromMarc ); -use C4::Koha; +use C4::Biblio qw( + AddBiblio + GetMarcFromKohaField + GetMarcPrice + GetMarcQuantity + TransformHtmlToXml +); +use C4::Items qw( AddItemFromMarc PrepareItemrecordDisplay ); use C4::Budgets; use C4::Acquisition; use C4::Suggestions; # GetSuggestion diff --git a/acqui/ajax-getauthvaluedropbox.pl b/acqui/ajax-getauthvaluedropbox.pl old mode 100755 new mode 100644 index 6d7034b8232..0afc725a9f7 --- a/acqui/ajax-getauthvaluedropbox.pl +++ b/acqui/ajax-getauthvaluedropbox.pl @@ -48,7 +48,7 @@ Default value for the dropbox. use Modern::Perl; use CGI qw ( -utf8 ); -use C4::Charset qw( NormalizeString ); +use C4::Charset (); use C4::Auth qw( check_api_auth ); use Koha::AuthorisedValues; diff --git a/acqui/basket.pl b/acqui/basket.pl old mode 100755 new mode 100644 index a82be8cc796..aae99ed777a --- a/acqui/basket.pl +++ b/acqui/basket.pl @@ -22,15 +22,12 @@ use Modern::Perl; use C4::Auth qw( get_template_and_user haspermission ); -use C4::Koha; use C4::Output qw( output_html_with_http_headers output_and_exit ); use CGI qw ( -utf8 ); use C4::Acquisition; use C4::Budgets; -use C4::Contract; -use C4::Debug; -use C4::Biblio; -use C4::Items qw( sub ); +use C4::Contract qw( GetContract ); +use C4::Debug qw( $debug ); use C4::Suggestions; use Koha::Biblios; use Koha::Acquisition::Baskets; @@ -38,7 +35,7 @@ use Koha::Acquisition::Booksellers; use Koha::Acquisition::Orders; use Koha::Libraries; use C4::Letters qw( SendAlerts ); -use Date::Calc qw/Add_Delta_Days/; +use Date::Calc qw( Add_Delta_Days ); use Koha::Database; use Koha::EDI qw( create_edi_order ); use Koha::CsvProfiles; diff --git a/acqui/basketgroup.pl b/acqui/basketgroup.pl old mode 100755 new mode 100644 index ccbcf591e62..9975a9d4386 --- a/acqui/basketgroup.pl +++ b/acqui/basketgroup.pl @@ -44,14 +44,28 @@ The bookseller who we want to display the baskets (and basketgroups) of. =cut use Modern::Perl; -use Carp; +use Carp qw( croak ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use CGI qw ( -utf8 ); -use File::Spec; - -use C4::Acquisition qw/CloseBasketgroup ReOpenBasketgroup GetOrders GetBasketsByBasketgroup GetBasketsByBookseller ModBasketgroup NewBasketgroup DelBasketgroup GetBasketgroups ModBasket GetBasketgroup GetBasket GetBasketGroupAsCSV get_rounded_price/; +use File::Spec (); + +use C4::Acquisition qw( + CloseBasketgroup + DelBasketgroup + get_rounded_price + GetBasketgroup + GetBasketGroupAsCSV + GetBasketgroups + GetBasketsByBasketgroup + GetBasketsByBookseller + GetOrders + ModBasket + ModBasketgroup + NewBasketgroup + ReOpenBasketgroup +); use Koha::EDI qw( get_edifact_ean create_edi_order ); use Koha::Biblioitems; diff --git a/acqui/basketheader.pl b/acqui/basketheader.pl old mode 100755 new mode 100644 index cc328931b0b..967343d3381 --- a/acqui/basketheader.pl +++ b/acqui/basketheader.pl @@ -51,7 +51,7 @@ use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Acquisition qw/GetBasket NewBasket ModBasketHeader/; -use C4::Contract qw/GetContracts/; +use C4::Contract qw( GetContracts ); use Koha::Acquisition::Booksellers; use Koha::Acquisition::Baskets; diff --git a/acqui/booksellers.pl b/acqui/booksellers.pl old mode 100755 new mode 100644 index 2e0a9944901..cf590c572cf --- a/acqui/booksellers.pl +++ b/acqui/booksellers.pl @@ -53,7 +53,6 @@ The id of the supplier whose baskets we will display use Modern::Perl; use C4::Auth qw( get_template_and_user ); -use C4::Biblio; use C4::Budgets; use C4::Output qw( output_html_with_http_headers ); use CGI qw ( -utf8 ); diff --git a/acqui/cancelorder.pl b/acqui/cancelorder.pl old mode 100755 new mode 100644 index ae40054e15c..074421b0269 --- a/acqui/cancelorder.pl +++ b/acqui/cancelorder.pl @@ -31,7 +31,7 @@ and add possibility to indicate a reason for cancellation use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Acquisition; diff --git a/acqui/check_budget_total.pl b/acqui/check_budget_total.pl old mode 100755 new mode 100644 diff --git a/acqui/check_uniqueness.pl b/acqui/check_uniqueness.pl old mode 100755 new mode 100644 index a564a325e5a..ab0fa1e34ef --- a/acqui/check_uniqueness.pl +++ b/acqui/check_uniqueness.pl @@ -32,9 +32,9 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use JSON; +use JSON qw( to_json ); use C4::Output qw( output_with_http_headers ); -use C4::Items qw( SearchItems ); +use C4::Items (); my $input = CGI->new; my @field = $input->multi_param('field[]'); diff --git a/acqui/duplicate_orders.pl b/acqui/duplicate_orders.pl old mode 100755 new mode 100644 index fdda9c50875..038adb80731 --- a/acqui/duplicate_orders.pl +++ b/acqui/duplicate_orders.pl @@ -28,7 +28,7 @@ use C4::Budgets qw(GetBudgetPeriods GetBudgetHierarchy CanUserUseBudget); use Koha::Acquisition::Baskets; use Koha::Acquisition::Currencies; use Koha::Acquisition::Orders; -use Koha::DateUtils qw(dt_from_string output_pref); +use Koha::DateUtils qw( dt_from_string output_pref ); my $input = CGI->new; my $basketno = $input->param('basketno'); diff --git a/acqui/edi_ean.pl b/acqui/edi_ean.pl old mode 100755 new mode 100644 index 76d61f8b497..0c08efe2aa2 --- a/acqui/edi_ean.pl +++ b/acqui/edi_ean.pl @@ -24,10 +24,9 @@ use Modern::Perl; use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Output qw( output_html_with_http_headers ); use Koha::Database; -use CGI; +use CGI (); my $schema = Koha::Database->new()->schema(); my @eans = $schema->resultset('EdifactEan')->search( diff --git a/acqui/edifactmsgs.pl b/acqui/edifactmsgs.pl old mode 100755 new mode 100644 index 8d85e72784d..667e225b3ec --- a/acqui/edifactmsgs.pl +++ b/acqui/edifactmsgs.pl @@ -18,10 +18,9 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Output qw( output_html_with_http_headers ); use Koha::Database; use Koha::EDI qw( process_invoice ); diff --git a/acqui/edimsg.pl b/acqui/edimsg.pl old mode 100755 new mode 100644 index 9827def3a4b..ed8e41dafae --- a/acqui/edimsg.pl +++ b/acqui/edimsg.pl @@ -18,7 +18,7 @@ use Modern::Perl; -use CGI; +use CGI (); use Koha::Database; use C4::Koha; use C4::Auth qw( get_template_and_user ); diff --git a/acqui/finishreceive.pl b/acqui/finishreceive.pl old mode 100755 new mode 100644 index 0b37dca95e9..5bdfae16e06 --- a/acqui/finishreceive.pl +++ b/acqui/finishreceive.pl @@ -27,14 +27,13 @@ use C4::Output; use C4::Context; use C4::Acquisition; use C4::Biblio qw( GetFrameworkCode GetMarcFromKohaField TransformHtmlToXml ); -use C4::Items qw( sub GetMarcItem ModItemFromMarc AddItemFromMarc ); +use C4::Items qw( AddItemFromMarc ); use C4::Search; use Koha::Number::Price; use Koha::Acquisition::Booksellers; use Koha::Acquisition::Orders; -use List::MoreUtils qw/any/; my $input=CGI->new; my $flagsrequired = {acquisition => 'order_receive'}; diff --git a/acqui/histsearch.pl b/acqui/histsearch.pl old mode 100755 new mode 100644 index 3ea062b76d9..8a266cfbcc7 --- a/acqui/histsearch.pl +++ b/acqui/histsearch.pl @@ -54,10 +54,8 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Acquisition; -use C4::Debug; -use C4::Koha; use Koha::AdditionalFields; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); my $input = CGI->new; my $do_search = $input->param('do_search') || 0; diff --git a/acqui/invoice-files.pl b/acqui/invoice-files.pl old mode 100755 new mode 100644 index 2b91e1619f9..71ec8bc8882 --- a/acqui/invoice-files.pl +++ b/acqui/invoice-files.pl @@ -29,7 +29,7 @@ Manage files associated with invoice use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Acquisition; diff --git a/acqui/invoice.pl b/acqui/invoice.pl old mode 100755 new mode 100644 index d8b4a468911..8dd5414a6d4 --- a/acqui/invoice.pl +++ b/acqui/invoice.pl @@ -36,7 +36,7 @@ use C4::Budgets; use Koha::Acquisition::Booksellers; use Koha::Acquisition::Currencies; -use Koha::DateUtils; +use Koha::DateUtils qw( output_pref ); use Koha::Misc::Files; use Koha::Acquisition::Invoice::Adjustments; diff --git a/acqui/invoices.pl b/acqui/invoices.pl old mode 100755 new mode 100644 index 82144f0298f..3350d6f2c35 --- a/acqui/invoices.pl +++ b/acqui/invoices.pl @@ -34,7 +34,7 @@ use C4::Output qw( output_html_with_http_headers ); use C4::Acquisition qw/GetInvoices/; use C4::Budgets; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Acquisition::Booksellers; my $input = CGI->new; diff --git a/acqui/lateorders-export.pl b/acqui/lateorders-export.pl old mode 100755 new mode 100644 index 64a881e5d7e..597941e19e0 --- a/acqui/lateorders-export.pl +++ b/acqui/lateorders-export.pl @@ -17,7 +17,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Encode; +use Encode (); use C4::Auth qw( get_template_and_user ); use C4::Acquisition; diff --git a/acqui/lateorders.pl b/acqui/lateorders.pl old mode 100755 new mode 100644 index d4e2e7a8666..300e060dc7a --- a/acqui/lateorders.pl +++ b/acqui/lateorders.pl @@ -46,12 +46,11 @@ To know on which branch this script have to display late order. use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Output qw( output_html_with_http_headers ); use C4::Context; use C4::Acquisition; -use C4::Letters qw( SendAlerts GetLetters ); -use Koha::DateUtils; +use C4::Letters qw( GetLetters SendAlerts ); +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Acquisition::Orders; use Koha::CsvProfiles; diff --git a/acqui/modordernotes.pl b/acqui/modordernotes.pl old mode 100755 new mode 100644 diff --git a/acqui/neworderempty.pl b/acqui/neworderempty.pl old mode 100755 new mode 100644 index ccbe9defd8c..2b26d96b136 --- a/acqui/neworderempty.pl +++ b/acqui/neworderempty.pl @@ -72,12 +72,18 @@ use C4::Auth qw( get_template_and_user ); use C4::Budgets; use C4::Acquisition; -use C4::Contract; +use C4::Contract qw( GetContract ); use C4::Suggestions; # GetSuggestion -use C4::Biblio qw( AddBiblio GetMarcPrice GetMarcStructure GetMarcFromKohaField GetBiblioData IsMarcStructureInternal GetMarcBiblio ); -use C4::Items qw( sub ); +use C4::Biblio qw( + AddBiblio + GetBiblioData + GetMarcBiblio + GetMarcFromKohaField + GetMarcPrice + GetMarcStructure + IsMarcStructureInternal +); use C4::Output qw( output_and_exit output_html_with_http_headers ); -use C4::Koha; use C4::Members; use C4::Search qw( FindDuplicate ); diff --git a/acqui/newordersubscription.pl b/acqui/newordersubscription.pl old mode 100755 new mode 100644 diff --git a/acqui/newordersuggestion.pl b/acqui/newordersuggestion.pl old mode 100755 new mode 100644 index 8606d22f62e..0545d11d071 --- a/acqui/newordersuggestion.pl +++ b/acqui/newordersuggestion.pl @@ -94,7 +94,6 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Suggestions; -use C4::Biblio; use C4::Budgets; use Koha::Acquisition::Booksellers; diff --git a/acqui/ordered.pl b/acqui/ordered.pl old mode 100755 new mode 100644 diff --git a/acqui/orderreceive.pl b/acqui/orderreceive.pl old mode 100755 new mode 100644 index 84b72063061..17392a32121 --- a/acqui/orderreceive.pl +++ b/acqui/orderreceive.pl @@ -67,10 +67,8 @@ use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Budgets qw/ GetBudget GetBudgetHierarchy CanUserUseBudget GetBudgetPeriods /; use C4::Members; -use C4::Items qw( sub ); use C4::Biblio qw( GetMarcStructure ); use C4::Suggestions; -use C4::Koha; use Koha::Acquisition::Booksellers; use Koha::Acquisition::Currencies; diff --git a/acqui/parcel.pl b/acqui/parcel.pl old mode 100755 new mode 100644 index 7317e056da4..be7929814a9 --- a/acqui/parcel.pl +++ b/acqui/parcel.pl @@ -59,8 +59,6 @@ use Modern::Perl; use C4::Auth qw( get_template_and_user ); use C4::Acquisition; use C4::Budgets; -use C4::Biblio; -use C4::Items qw( sub ); use CGI qw ( -utf8 ); use C4::Output qw( output_html_with_http_headers ); use C4::Suggestions; @@ -69,10 +67,8 @@ use Koha::Acquisition::Baskets; use Koha::Acquisition::Bookseller; use Koha::Acquisition::Orders; use Koha::Biblios; -use Koha::DateUtils; use Koha::Biblios; -use JSON; my $input = CGI->new; diff --git a/acqui/parcels.pl b/acqui/parcels.pl old mode 100755 new mode 100644 index 8f837915813..bf0e7871880 --- a/acqui/parcels.pl +++ b/acqui/parcels.pl @@ -75,7 +75,7 @@ use C4::Acquisition; use C4::Budgets; use Koha::Acquisition::Booksellers; -use Koha::DateUtils qw( output_pref dt_from_string ); +use Koha::DateUtils qw( dt_from_string output_pref ); my $input = CGI->new; my $booksellerid = $input->param('booksellerid'); diff --git a/acqui/showorder.pl b/acqui/showorder.pl old mode 100755 new mode 100644 diff --git a/acqui/spent.pl b/acqui/spent.pl old mode 100755 new mode 100644 diff --git a/acqui/supplier.pl b/acqui/supplier.pl old mode 100755 new mode 100644 index 8733d663cd3..7e5f961ade6 --- a/acqui/supplier.pl +++ b/acqui/supplier.pl @@ -42,8 +42,7 @@ To know the bookseller this script has to display details. use Modern::Perl; use C4::Auth qw( get_template_and_user ); -use C4::Contract; -use C4::Biblio; +use C4::Contract qw( GetContracts ); use C4::Output qw( output_html_with_http_headers ); use CGI qw ( -utf8 ); diff --git a/acqui/transferorder.pl b/acqui/transferorder.pl old mode 100755 new mode 100644 diff --git a/acqui/uncertainprice.pl b/acqui/uncertainprice.pl old mode 100755 new mode 100644 index 8a1dee628d8..d846008aec6 --- a/acqui/uncertainprice.pl +++ b/acqui/uncertainprice.pl @@ -50,7 +50,6 @@ use C4::Output qw( output_html_with_http_headers ); use CGI qw ( -utf8 ); use C4::Acquisition qw/SearchOrders GetOrder ModOrder/; -use C4::Biblio qw/GetBiblioData/; use Koha::Acquisition::Booksellers; use Koha::Acquisition::Baskets; diff --git a/acqui/updatesupplier.pl b/acqui/updatesupplier.pl old mode 100755 new mode 100644 index 51d55ba6a1b..b195c88fb6b --- a/acqui/updatesupplier.pl +++ b/acqui/updatesupplier.pl @@ -47,11 +47,9 @@ contact_serialsprimary. =cut use Modern::Perl; -use List::Util; use C4::Context; use C4::Auth qw( checkauth ); -use C4::Biblio; use C4::Output; use Koha::Acquisition::Bookseller::Contacts; diff --git a/acqui/z3950_search.pl b/acqui/z3950_search.pl old mode 100755 new mode 100644 index 096bff4ef04..d596cbf227c --- a/acqui/z3950_search.pl +++ b/acqui/z3950_search.pl @@ -26,7 +26,6 @@ use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Context; use C4::Breeding qw( Z3950Search ); -use C4::Koha; use Koha::Acquisition::Booksellers; use Koha::BiblioFrameworks; diff --git a/admin/add_user_search.pl b/admin/add_user_search.pl old mode 100755 new mode 100644 diff --git a/admin/additional-fields.pl b/admin/additional-fields.pl old mode 100755 new mode 100644 index e7de2869dc6..259504591e2 --- a/admin/additional-fields.pl +++ b/admin/additional-fields.pl @@ -17,9 +17,8 @@ # with Koha; if not, see . use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Output qw( output_html_with_http_headers ); use Koha::AdditionalFields; diff --git a/admin/admin-home.pl b/admin/admin-home.pl old mode 100755 new mode 100644 diff --git a/admin/adveditorshortcuts.pl b/admin/adveditorshortcuts.pl old mode 100755 new mode 100644 index 4cd4d71f691..5606cd962fe --- a/admin/adveditorshortcuts.pl +++ b/admin/adveditorshortcuts.pl @@ -34,13 +34,11 @@ This script allows the user to redefine the keyboard shortcuts for the advacned =cut use Modern::Perl; -use Encode; use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use CGI qw ( -utf8 ); -use C4::Koha; use Koha::KeyboardShortcuts; my $input = CGI->new; diff --git a/admin/aqbudgetperiods.pl b/admin/aqbudgetperiods.pl old mode 100755 new mode 100644 index 5043480d83a..05327c2a8e5 --- a/admin/aqbudgetperiods.pl +++ b/admin/aqbudgetperiods.pl @@ -47,16 +47,13 @@ script to administer the budget periods table use Modern::Perl; use CGI qw ( -utf8 ); -use List::Util qw/min/; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::Database; -use C4::Koha; use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Acquisition; use C4::Budgets; -use C4::Debug; use Koha::Acquisition::Currencies; my $dbh = C4::Context->dbh; diff --git a/admin/aqbudgets.pl b/admin/aqbudgets.pl old mode 100755 new mode 100644 index 5303773cf65..069c3a2bf4e --- a/admin/aqbudgets.pl +++ b/admin/aqbudgets.pl @@ -22,7 +22,6 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use List::Util qw/min/; use Koha::Database; use C4::Auth qw( get_template_and_user ); @@ -31,8 +30,6 @@ use C4::Acquisition; use C4::Budgets; use C4::Context; use C4::Output qw( output_html_with_http_headers output_and_exit ); -use C4::Koha; -use C4::Debug; use Koha::Acquisition::Currencies; use Koha::Patrons; diff --git a/admin/aqcontract.pl b/admin/aqcontract.pl old mode 100755 new mode 100644 index 0a6209c6b09..714a906ab56 --- a/admin/aqcontract.pl +++ b/admin/aqcontract.pl @@ -25,8 +25,14 @@ use CGI qw ( -utf8 ); use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Contract; -use Koha::DateUtils; +use C4::Contract qw( + AddContract + DelContract + GetContract + GetContracts + ModContract +); +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Acquisition::Booksellers; diff --git a/admin/aqplan.pl b/admin/aqplan.pl old mode 100755 new mode 100644 index ba58fc0bc42..97b4bf7252c --- a/admin/aqplan.pl +++ b/admin/aqplan.pl @@ -22,10 +22,9 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use List::Util qw/min/; -use Date::Calc qw/Delta_YMD Easter_Sunday Today Decode_Date_EU/; -use Date::Manip qw/ ParseDate UnixDate DateCalc/; -use Text::CSV_XS; +use Date::Calc qw( Delta_YMD ); +use Date::Manip qw( DateCalc UnixDate ); +use Text::CSV_XS (); use C4::Acquisition; use C4::Budgets; @@ -33,7 +32,6 @@ use C4::Context; use C4::Output qw( output_html_with_http_headers ); use C4::Koha; use C4::Auth qw( get_template_and_user ); -use C4::Debug; use Koha::Acquisition::Currencies; our $input = CGI->new; diff --git a/admin/audio_alerts.pl b/admin/audio_alerts.pl old mode 100755 new mode 100644 index 7ac73ed978b..5fd6d7fb551 --- a/admin/audio_alerts.pl +++ b/admin/audio_alerts.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use Koha::AudioAlert; diff --git a/admin/auth_subfields_structure.pl b/admin/auth_subfields_structure.pl old mode 100755 new mode 100644 index 2bee6f98d99..dff31f8ba18 --- a/admin/auth_subfields_structure.pl +++ b/admin/auth_subfields_structure.pl @@ -22,7 +22,6 @@ use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); use CGI qw ( -utf8 ); use C4::Context; -use C4::Koha; use Koha::Authority::Types; use Koha::AuthorisedValues; diff --git a/admin/auth_tag_structure.pl b/admin/auth_tag_structure.pl old mode 100755 new mode 100644 index 1346cbe3354..04ffd72ee76 --- a/admin/auth_tag_structure.pl +++ b/admin/auth_tag_structure.pl @@ -21,7 +21,6 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Context; use C4::Output qw( output_html_with_http_headers ); use C4::Context; diff --git a/admin/authorised_values.pl b/admin/authorised_values.pl old mode 100755 new mode 100644 index d0de42265ef..ad5b366f2b1 --- a/admin/authorised_values.pl +++ b/admin/authorised_values.pl @@ -20,11 +20,11 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use List::MoreUtils qw(any); +use List::MoreUtils qw( any ); use C4::Auth qw( get_template_and_user ); use C4::Context; -use C4::Koha qw( getImageSets getitemtypeimagelocation ); +use C4::Koha qw( getitemtypeimagelocation ); use C4::Output qw( output_html_with_http_headers ); use Koha::AuthorisedValues; diff --git a/admin/authtypes.pl b/admin/authtypes.pl old mode 100755 new mode 100644 diff --git a/admin/background_jobs.pl b/admin/background_jobs.pl old mode 100755 new mode 100644 index 9ed3ac7f82f..cf0765b93f1 --- a/admin/background_jobs.pl +++ b/admin/background_jobs.pl @@ -17,8 +17,6 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use JSON qw( decode_json ); -use Try::Tiny; use C4::Context; use C4::Auth qw( get_template_and_user ); diff --git a/admin/biblio_framework.pl b/admin/biblio_framework.pl old mode 100755 new mode 100644 diff --git a/admin/branch_transfer_limits.pl b/admin/branch_transfer_limits.pl old mode 100755 new mode 100644 index c967c3e9a73..1cd0085c44d --- a/admin/branch_transfer_limits.pl +++ b/admin/branch_transfer_limits.pl @@ -24,7 +24,6 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::Koha; use C4::Circulation qw( DeleteBranchTransferLimits CreateBranchTransferLimit IsBranchTransferAllowed ); my $input = CGI->new; diff --git a/admin/branches.pl b/admin/branches.pl old mode 100755 new mode 100644 index 860ed434891..d94d4bf6ed6 --- a/admin/branches.pl +++ b/admin/branches.pl @@ -21,12 +21,11 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Try::Tiny; +use Try::Tiny qw( catch try ); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::Koha; use Koha::Database; use Koha::Patrons; diff --git a/admin/cash_registers.pl b/admin/cash_registers.pl old mode 100755 new mode 100644 index f76d73bd8bc..f3a3052554f --- a/admin/cash_registers.pl +++ b/admin/cash_registers.pl @@ -20,8 +20,8 @@ use strict; use warnings; -use CGI; -use Try::Tiny; +use CGI (); +use Try::Tiny qw( catch try ); use C4::Auth qw( get_template_and_user ); use Koha::Libraries; diff --git a/admin/categories.pl b/admin/categories.pl old mode 100755 new mode 100644 index b57ecc500b2..66c152204d3 --- a/admin/categories.pl +++ b/admin/categories.pl @@ -27,7 +27,7 @@ use C4::Output qw( output_html_with_http_headers ); use C4::Form::MessagingPreferences; use Koha::Patrons; use Koha::Database; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Patron::Categories; use Koha::Libraries; diff --git a/admin/check_budget_parent.pl b/admin/check_budget_parent.pl old mode 100755 new mode 100644 diff --git a/admin/check_parent_total.pl b/admin/check_parent_total.pl old mode 100755 new mode 100644 diff --git a/admin/checkmarc.pl b/admin/checkmarc.pl old mode 100755 new mode 100644 index 4d9d85143a1..b20982369b4 --- a/admin/checkmarc.pl +++ b/admin/checkmarc.pl @@ -23,7 +23,6 @@ use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); use CGI qw ( -utf8 ); use C4::Context; -use C4::Biblio; my $input = CGI->new; diff --git a/admin/cities.pl b/admin/cities.pl old mode 100755 new mode 100644 diff --git a/admin/classsources.pl b/admin/classsources.pl old mode 100755 new mode 100644 index 3525f36131a..2e15932d9e0 --- a/admin/classsources.pl +++ b/admin/classsources.pl @@ -24,7 +24,6 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::Koha; use C4::ClassSortRoutine qw( GetSortRoutineNames ); use C4::ClassSplitRoutine qw( GetSplitRoutineNames ); use Koha::ClassSources; diff --git a/admin/clone-rules.pl b/admin/clone-rules.pl old mode 100755 new mode 100644 index 1acff309113..734a5d732f0 --- a/admin/clone-rules.pl +++ b/admin/clone-rules.pl @@ -30,8 +30,6 @@ use CGI qw ( -utf8 ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; -use C4::Debug; use Koha::CirculationRules; my $input = CGI->new; diff --git a/admin/columns_settings.pl b/admin/columns_settings.pl old mode 100755 new mode 100644 index de9aeb9b947..a28ae92bb5a --- a/admin/columns_settings.pl +++ b/admin/columns_settings.pl @@ -1,7 +1,7 @@ #!/usr/bin/perl use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); diff --git a/admin/credit_types.pl b/admin/credit_types.pl old mode 100755 new mode 100644 index f344f353ae4..272ddb05188 --- a/admin/credit_types.pl +++ b/admin/credit_types.pl @@ -19,7 +19,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Try::Tiny; +use Try::Tiny qw( catch try ); use C4::Context; use C4::Auth qw( get_template_and_user ); diff --git a/admin/currency.pl b/admin/currency.pl old mode 100755 new mode 100644 diff --git a/admin/debit_types.pl b/admin/debit_types.pl old mode 100755 new mode 100644 index 5760b5eab29..c2bde89fc60 --- a/admin/debit_types.pl +++ b/admin/debit_types.pl @@ -19,7 +19,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Try::Tiny; +use Try::Tiny qw( catch try ); use C4::Context; use C4::Auth qw( get_template_and_user ); diff --git a/admin/desks.pl b/admin/desks.pl old mode 100755 new mode 100644 diff --git a/admin/didyoumean.pl b/admin/didyoumean.pl old mode 100755 new mode 100644 index ab2c34dd425..a5fb8444ebf --- a/admin/didyoumean.pl +++ b/admin/didyoumean.pl @@ -6,8 +6,8 @@ use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use Koha::SuggestionEngine; -use Module::Load::Conditional qw(can_load); -use JSON; +use Module::Load::Conditional qw( can_load ); +use JSON qw( from_json ); my $input = CGI->new; diff --git a/admin/edi_accounts.pl b/admin/edi_accounts.pl old mode 100755 new mode 100644 index 293f7ef6662..ad3a2c274ab --- a/admin/edi_accounts.pl +++ b/admin/edi_accounts.pl @@ -18,7 +18,7 @@ # along with Koha; if not, see . use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use Koha::Database; diff --git a/admin/edi_ean_accounts.pl b/admin/edi_ean_accounts.pl old mode 100755 new mode 100644 index 87ebe458c71..222dc252492 --- a/admin/edi_ean_accounts.pl +++ b/admin/edi_ean_accounts.pl @@ -18,7 +18,7 @@ # along with Koha; if not, see . use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use Koha::Database; diff --git a/admin/import_export_framework.pl b/admin/import_export_framework.pl old mode 100755 new mode 100644 index 45ba9e2ba2c..735915d49fd --- a/admin/import_export_framework.pl +++ b/admin/import_export_framework.pl @@ -23,7 +23,7 @@ use CGI qw ( -utf8 ); use CGI::Cookie; use C4::Context; use C4::Auth qw( check_cookie_auth ); -use C4::ImportExportFramework qw( ExportFramework createODS ImportFramework ); +use C4::ImportExportFramework qw( createODS ExportFramework ImportFramework ); my %cookies = CGI::Cookie->fetch(); my $authenticated = 0; diff --git a/admin/item_circulation_alerts.pl b/admin/item_circulation_alerts.pl old mode 100755 new mode 100644 index ba9dd5b3c91..67b71a32e2f --- a/admin/item_circulation_alerts.pl +++ b/admin/item_circulation_alerts.pl @@ -18,9 +18,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use File::Basename; -use Encode; -use JSON; +use JSON qw( encode_json ); #use Data::Dump 'pp'; use C4::Auth qw( get_template_and_user ); diff --git a/admin/items_search_field.pl b/admin/items_search_field.pl old mode 100755 new mode 100644 index 569dce65bbc..b3259296014 --- a/admin/items_search_field.pl +++ b/admin/items_search_field.pl @@ -17,7 +17,7 @@ # along with Koha; if not, see . use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/admin/items_search_fields.pl b/admin/items_search_fields.pl old mode 100755 new mode 100644 index 0e62eb67c66..3498bf3ceee --- a/admin/items_search_fields.pl +++ b/admin/items_search_fields.pl @@ -17,7 +17,7 @@ # along with Koha; if not, see . use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/admin/itemtypes.pl b/admin/itemtypes.pl old mode 100755 new mode 100644 index dfec5f1e6ee..d3bb3dc248e --- a/admin/itemtypes.pl +++ b/admin/itemtypes.pl @@ -25,7 +25,6 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use File::Spec; use C4::Koha qw( getImageSets GetAuthorisedValues ); use C4::Context; diff --git a/admin/koha2marclinks.pl b/admin/koha2marclinks.pl old mode 100755 new mode 100644 index 516bf28c19d..990ad4914c1 --- a/admin/koha2marclinks.pl +++ b/admin/koha2marclinks.pl @@ -23,7 +23,6 @@ use CGI qw ( -utf8 ); use Koha::Database; use C4::Auth qw( get_template_and_user ); -use C4::Biblio; use C4::Output qw( output_html_with_http_headers ); use Koha::BiblioFrameworks; use Koha::Caches; diff --git a/admin/library_groups.pl b/admin/library_groups.pl old mode 100755 new mode 100644 diff --git a/admin/localization.pl b/admin/localization.pl old mode 100755 new mode 100644 diff --git a/admin/marc_subfields_structure.pl b/admin/marc_subfields_structure.pl old mode 100755 new mode 100644 diff --git a/admin/marctagstructure.pl b/admin/marctagstructure.pl old mode 100755 new mode 100644 index 4522b508968..0580f2f734e --- a/admin/marctagstructure.pl +++ b/admin/marctagstructure.pl @@ -21,7 +21,6 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Context; use C4::Output qw( output_html_with_http_headers ); use C4::Context; diff --git a/admin/matching-rules.pl b/admin/matching-rules.pl old mode 100755 new mode 100644 index 5c5b7bdbed1..b1d8da95067 --- a/admin/matching-rules.pl +++ b/admin/matching-rules.pl @@ -24,7 +24,6 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::Koha; use C4::Matcher qw/valid_normalization_routines/; my $script_name = "/cgi-bin/koha/admin/matching-rules.pl"; diff --git a/admin/oai_set_mappings.pl b/admin/oai_set_mappings.pl old mode 100755 new mode 100644 index 2b828faa520..445f4788178 --- a/admin/oai_set_mappings.pl +++ b/admin/oai_set_mappings.pl @@ -35,9 +35,8 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::OAI::Sets; +use C4::OAI::Sets qw( GetOAISet GetOAISetMappings ModOAISetMappings ); -use Data::Dumper; my $input = CGI->new; my ($template, $loggedinuser, $cookie, $flags) = get_template_and_user( { diff --git a/admin/oai_sets.pl b/admin/oai_sets.pl old mode 100755 new mode 100644 index 65a756a9237..baeba031796 --- a/admin/oai_sets.pl +++ b/admin/oai_sets.pl @@ -31,9 +31,8 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::OAI::Sets; +use C4::OAI::Sets qw( AddOAISet DelOAISet GetOAISet GetOAISets ModOAISet ); -use Data::Dumper; my $input = CGI->new; my ($template, $loggedinuser, $cookie, $flags) = get_template_and_user( { diff --git a/admin/overdrive.pl b/admin/overdrive.pl old mode 100755 new mode 100644 diff --git a/admin/patron-attr-types.pl b/admin/patron-attr-types.pl old mode 100755 new mode 100644 index a02f991d7e2..2cf2bf6f3be --- a/admin/patron-attr-types.pl +++ b/admin/patron-attr-types.pl @@ -22,12 +22,11 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use List::MoreUtils qw/uniq/; +use List::MoreUtils qw( uniq ); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::Koha; use Koha::Patron::Attribute::Types; use Koha::AuthorisedValues; diff --git a/admin/preferences.pl b/admin/preferences.pl old mode 100755 new mode 100644 index f9f16dafab4..1b388a3777b --- a/admin/preferences.pl +++ b/admin/preferences.pl @@ -24,16 +24,14 @@ use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Koha qw( getallthemes ); use C4::Languages qw( getTranslatedLanguages ); -use C4::ClassSource qw( GetClassSources GetClassSource ); -use C4::Log; +use C4::ClassSource qw( GetClassSources ); use C4::Output qw( output_html_with_http_headers ); use C4::Templates; use Koha::Acquisition::Currencies; -use File::Spec; -use IO::File; -use YAML::XS; -use Encode; -use List::MoreUtils qw(any); +use IO::File (); +use YAML::XS (); +use Encode (); +use List::MoreUtils qw( any ); # use Smart::Comments; # diff --git a/admin/searchengine/elasticsearch/mappings.pl b/admin/searchengine/elasticsearch/mappings.pl old mode 100755 new mode 100644 index 4f719208231..49cda42c1ed --- a/admin/searchengine/elasticsearch/mappings.pl +++ b/admin/searchengine/elasticsearch/mappings.pl @@ -16,13 +16,13 @@ # along with Koha; if not, see . use Modern::Perl; -use CGI; -use Scalar::Util qw(looks_like_number); +use CGI (); +use Scalar::Util qw( looks_like_number ); use List::Util qw( first ); use C4::Koha; use C4::Output; use C4::Auth; -use C4::Log; +use C4::Log (); use Koha::SearchEngine::Elasticsearch; use Koha::SearchEngine::Elasticsearch::QueryBuilder; @@ -30,8 +30,8 @@ use Koha::SearchMarcMaps; use Koha::SearchFields; use Koha::Caches; -use Try::Tiny; -use Module::Load::Conditional qw(can_load); +use Try::Tiny qw( catch try ); +use Module::Load::Conditional qw( can_load ); my $input = CGI->new; diff --git a/admin/share_content.pl b/admin/share_content.pl old mode 100755 new mode 100644 index 5bd9d2caca8..84f2bb69483 --- a/admin/share_content.pl +++ b/admin/share_content.pl @@ -18,7 +18,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use JSON; +use JSON qw( to_json ); use HTTP::Request; use C4::Auth qw( get_template_and_user ); diff --git a/admin/smart-rules.pl b/admin/smart-rules.pl old mode 100755 new mode 100644 index 027c969bc05..f43ec8f435e --- a/admin/smart-rules.pl +++ b/admin/smart-rules.pl @@ -22,9 +22,8 @@ use CGI qw ( -utf8 ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; -use C4::Debug; -use Koha::DateUtils; +use C4::Debug qw( $debug ); +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Database; use Koha::Logger; use Koha::Libraries; diff --git a/admin/sms_providers.pl b/admin/sms_providers.pl old mode 100755 new mode 100644 index bea1805e6db..1d383ede0b1 --- a/admin/sms_providers.pl +++ b/admin/sms_providers.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Context; use C4::Auth qw( get_template_and_user ); diff --git a/admin/smtp_servers.pl b/admin/smtp_servers.pl old mode 100755 new mode 100644 index 14992a45ff9..8c53bfc4be0 --- a/admin/smtp_servers.pl +++ b/admin/smtp_servers.pl @@ -20,8 +20,8 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Scalar::Util qw(blessed); -use Try::Tiny; +use Scalar::Util qw( blessed ); +use Try::Tiny qw( catch try ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/admin/sru_modmapping.pl b/admin/sru_modmapping.pl old mode 100755 new mode 100644 index 67023772e39..d7edafeafa1 --- a/admin/sru_modmapping.pl +++ b/admin/sru_modmapping.pl @@ -18,7 +18,7 @@ # along with Koha; if not, see . use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/admin/systempreferences.pl b/admin/systempreferences.pl old mode 100755 new mode 100644 index 0665effe352..58eb9775d21 --- a/admin/systempreferences.pl +++ b/admin/systempreferences.pl @@ -43,14 +43,14 @@ ALSO : use Modern::Perl; use CGI qw ( -utf8 ); -use MIME::Base64; +use MIME::Base64 qw( encode_base64 ); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Koha qw( getallthemes ); use C4::Languages qw( getTranslatedLanguages ); -use C4::ClassSource qw( GetClassSources GetClassSource ); +use C4::ClassSource qw( GetClassSources ); use C4::Output qw( output_html_with_http_headers ); -use YAML::XS; +use YAML::XS (); my %tabsysprefs; #we do no longer need to keep track of a tab per pref (yaml) diff --git a/admin/transfer_limits.pl b/admin/transfer_limits.pl old mode 100755 new mode 100644 index f22921c89ff..a0eb99b6569 --- a/admin/transfer_limits.pl +++ b/admin/transfer_limits.pl @@ -23,7 +23,6 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::Koha; use C4::Circulation qw{ IsBranchTransferAllowed DeleteBranchTransferLimits CreateBranchTransferLimit }; diff --git a/admin/transport-cost-matrix.pl b/admin/transport-cost-matrix.pl old mode 100755 new mode 100644 index 2305ee3aefb..791a4f46610 --- a/admin/transport-cost-matrix.pl +++ b/admin/transport-cost-matrix.pl @@ -22,13 +22,10 @@ use CGI qw ( -utf8 ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; -use C4::Debug; use C4::HoldsQueue qw( TransportCostMatrix UpdateTransportCostMatrix ); use Koha::Libraries; -use Data::Dumper; my $input = CGI->new; diff --git a/admin/usage_statistics.pl b/admin/usage_statistics.pl old mode 100755 new mode 100644 index bad5e4d556c..78d07768d39 --- a/admin/usage_statistics.pl +++ b/admin/usage_statistics.pl @@ -20,7 +20,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use Koha::DateUtils qw( dt_from_string output_pref ); +use Koha::DateUtils qw( output_pref ); use Koha::Libraries; my $query = CGI->new; diff --git a/admin/z3950servers.pl b/admin/z3950servers.pl old mode 100755 new mode 100644 diff --git a/api/v1/app.pl b/api/v1/app.pl old mode 100755 new mode 100644 index 93f57f207f1..610a848212f --- a/api/v1/app.pl +++ b/api/v1/app.pl @@ -17,5 +17,5 @@ use Modern::Perl; -require Mojolicious::Commands; +use Mojolicious::Commands (); Mojolicious::Commands->start_app('Koha::REST::V1'); diff --git a/authorities/auth_finder.pl b/authorities/auth_finder.pl old mode 100755 new mode 100644 index 7c75bbe0baa..a64c13d260c --- a/authorities/auth_finder.pl +++ b/authorities/auth_finder.pl @@ -25,7 +25,6 @@ use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Acquisition; -use C4::Koha; use Koha::SearchEngine::Search; use Koha::SearchEngine::QueryBuilder; diff --git a/authorities/authorities-home.pl b/authorities/authorities-home.pl old mode 100755 new mode 100644 index 829e65c1a17..be3d5c42d0e --- a/authorities/authorities-home.pl +++ b/authorities/authorities-home.pl @@ -20,7 +20,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use URI::Escape; +use URI::Escape qw( uri_escape_utf8 ); use POSIX qw( ceil ); use C4::Context; @@ -29,7 +29,6 @@ use C4::Output qw( output_and_exit pagination_bar output_html_with_http_headers use C4::Auth qw( get_template_and_user ); use C4::Acquisition; use C4::Koha; -use C4::Biblio; use C4::Search::History; use Koha::Authority::Types; diff --git a/authorities/authorities.pl b/authorities/authorities.pl old mode 100755 new mode 100644 index c3735984ff0..6845491ea6d --- a/authorities/authorities.pl +++ b/authorities/authorities.pl @@ -26,8 +26,7 @@ use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); use C4::ImportBatch qw( sub GetImportRecordMarc ); use C4::Context; -use C4::Koha; -use Date::Calc qw(Today); +use Date::Calc qw( Today ); use MARC::File::USMARC; use MARC::File::XML; use C4::Biblio qw( TransformHtmlToMarc ); diff --git a/authorities/blinddetail-biblio-search.pl b/authorities/blinddetail-biblio-search.pl old mode 100755 new mode 100644 index 123bf8a3f4c..de6c7f32afd --- a/authorities/blinddetail-biblio-search.pl +++ b/authorities/blinddetail-biblio-search.pl @@ -43,8 +43,6 @@ use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use CGI qw ( -utf8 ); -use MARC::Record; -use C4::Koha; use Koha::Authorities; use Koha::Authority::Types; diff --git a/authorities/detail-biblio-search.pl b/authorities/detail-biblio-search.pl old mode 100755 new mode 100644 index b7b3e1ba231..53d497666af --- a/authorities/detail-biblio-search.pl +++ b/authorities/detail-biblio-search.pl @@ -43,8 +43,6 @@ use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use CGI qw ( -utf8 ); -use MARC::Record; -use C4::Koha; # use C4::Biblio; # use C4::Catalogue; diff --git a/authorities/detail.pl b/authorities/detail.pl old mode 100755 new mode 100644 index aa7fdd3f996..7b9556b9f6f --- a/authorities/detail.pl +++ b/authorities/detail.pl @@ -43,8 +43,7 @@ use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use CGI qw ( -utf8 ); -use MARC::Record; -use C4::Koha qw( display_marc_indicators ); +use C4::Koha (); use Koha::Authorities; use Koha::Authority::Types; diff --git a/authorities/export.pl b/authorities/export.pl old mode 100755 new mode 100644 diff --git a/authorities/merge.pl b/authorities/merge.pl old mode 100755 new mode 100644 index f759d4ff607..37e5116115a --- a/authorities/merge.pl +++ b/authorities/merge.pl @@ -22,7 +22,6 @@ use CGI qw ( -utf8 ); use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Biblio qw( TransformHtmlToMarc ); use Koha::Authority::MergeRequests; diff --git a/authorities/merge_ajax.pl b/authorities/merge_ajax.pl old mode 100755 new mode 100644 index f764232e0e1..26005eb9ed9 --- a/authorities/merge_ajax.pl +++ b/authorities/merge_ajax.pl @@ -4,7 +4,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); use CGI::Cookie; # need to check cookies before CGI parses the POST request -use JSON; +use JSON qw( encode_json ); use C4::Context; use C4::Auth qw( check_cookie_auth ); diff --git a/authorities/ysearch.pl b/authorities/ysearch.pl old mode 100755 new mode 100644 index 7d743904269..fc3d51fa858 --- a/authorities/ysearch.pl +++ b/authorities/ysearch.pl @@ -29,7 +29,7 @@ This script allows ajax call for dynamic authorities search use CGI qw ( -utf8 ); use Modern::Perl; -use JSON; +use JSON qw( to_json ); use C4::Context; use C4::Charset qw( nsb_clean ); diff --git a/basket/basket.pl b/basket/basket.pl old mode 100755 new mode 100644 index 50bea3082dd..30f73b8783e --- a/basket/basket.pl +++ b/basket/basket.pl @@ -19,8 +19,15 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Koha; -use C4::Biblio qw( GetBiblioData GetMarcBiblio GetMarcAuthors GetMarcSubjects GetMarcSeries GetMarcUrls ); -use C4::Items qw( sub GetItemsInfo ); +use C4::Biblio qw( + GetBiblioData + GetMarcAuthors + GetMarcBiblio + GetMarcSeries + GetMarcSubjects + GetMarcUrls +); +use C4::Items qw( GetItemsInfo ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/basket/downloadcart.pl b/basket/downloadcart.pl old mode 100755 new mode 100644 index 506c0ee1069..c1e80bf40d6 --- a/basket/downloadcart.pl +++ b/basket/downloadcart.pl @@ -20,14 +20,13 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Encode qw(encode); +use Encode qw( encode ); use C4::Auth qw( get_template_and_user ); use C4::Biblio qw( GetMarcBiblio ); -use C4::Items; use C4::Output qw( output_html_with_http_headers ); use C4::Record; -use C4::Ris; +use C4::Ris qw( marc2ris ); use Koha::CsvProfiles; diff --git a/basket/sendbasket.pl b/basket/sendbasket.pl old mode 100755 new mode 100644 index 565dd3d0c51..7380f6a0c59 --- a/basket/sendbasket.pl +++ b/basket/sendbasket.pl @@ -18,12 +18,17 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Encode qw(encode); -use Carp; -use Try::Tiny; - -use C4::Biblio qw( GetBiblioData GetMarcBiblio GetMarcAuthors GetMarcSubjects ); -use C4::Items qw( sub GetItemsInfo ); +use Encode (); +use Carp qw( carp ); +use Try::Tiny qw( catch try ); + +use C4::Biblio qw( + GetBiblioData + GetMarcAuthors + GetMarcBiblio + GetMarcSubjects +); +use C4::Items qw( GetItemsInfo ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit output_html_with_http_headers ); use C4::Templates (); diff --git a/catalogue/ISBDdetail.pl b/catalogue/ISBDdetail.pl old mode 100755 new mode 100644 index 103a6d473e0..970912d21e9 --- a/catalogue/ISBDdetail.pl +++ b/catalogue/ISBDdetail.pl @@ -35,14 +35,12 @@ This script needs a biblionumber as parameter use Modern::Perl; -use HTML::Entities; +use HTML::Entities (); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use CGI qw ( -utf8 ); -use C4::Koha; -use C4::Biblio qw( GetMarcBiblio GetFrameworkCode GetISBDView GetBiblioData ); -use C4::Items qw( sub ); +use C4::Biblio qw( GetBiblioData GetFrameworkCode GetISBDView GetMarcBiblio ); use C4::Serials qw( CountSubscriptionFromBiblionumber GetSubscription GetSubscriptionsFromBiblionumber ); use C4::Search qw( z3950_search_args enabled_staff_search_views ); diff --git a/catalogue/MARCdetail.pl b/catalogue/MARCdetail.pl old mode 100755 new mode 100644 index 747e65ecbb1..e40cf76ed1d --- a/catalogue/MARCdetail.pl +++ b/catalogue/MARCdetail.pl @@ -45,15 +45,20 @@ the items attached to the biblio use Modern::Perl; use CGI qw ( -utf8 ); -use HTML::Entities; +use HTML::Entities (); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::Koha qw( display_marc_indicators ); -use MARC::Record; -use C4::Biblio qw( GetFrameworkCode GetMarcBiblio GetMarcStructure GetBiblioData GetAuthorisedValueDesc GetMarcFromKohaField ); -use C4::Items qw( sub ); +use C4::Koha (); +use C4::Biblio qw( + GetAuthorisedValueDesc + GetBiblioData + GetFrameworkCode + GetMarcBiblio + GetMarcFromKohaField + GetMarcStructure +); use C4::Acquisition; use C4::Serials qw( CountSubscriptionFromBiblionumber GetSubscription GetSubscriptionsFromBiblionumber ); use C4::Search qw( z3950_search_args enabled_staff_search_views ); @@ -61,7 +66,7 @@ use C4::Search qw( z3950_search_args enabled_staff_search_views ); use Koha::Biblios; use Koha::BiblioFrameworks; use Koha::Patrons; -use Koha::DateUtils; +use Koha::DateUtils qw( output_pref ); use Koha::Virtualshelves; use List::MoreUtils qw( uniq ); diff --git a/catalogue/detail.pl b/catalogue/detail.pl old mode 100755 new mode 100644 index 9a8e2e332b7..e545316da09 --- a/catalogue/detail.pl +++ b/catalogue/detail.pl @@ -19,24 +19,30 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use HTML::Entities; -use Try::Tiny; +use HTML::Entities (); use C4::Auth qw( get_template_and_user ); use C4::Context; -use C4::Koha qw( GetNormalizedUPC GetNormalizedEAN GetNormalizedOCLCNumber GetNormalizedISBN getitemtypeimagelocation GetAuthorisedValues ); +use C4::Koha qw( + GetAuthorisedValues + getitemtypeimagelocation + GetNormalizedEAN + GetNormalizedISBN + GetNormalizedOCLCNumber + GetNormalizedUPC +); use C4::Serials qw( CountSubscriptionFromBiblionumber SearchSubscriptions GetLatestSerials ); use C4::Output qw( output_html_with_http_headers ); -use C4::Biblio qw( GetMarcBiblio GetFrameworkCode GetBiblioData ); -use C4::Items qw( GetItemsInfo GetHostItemsInfo sub GetAnalyticsCount ); +use C4::Biblio qw( GetBiblioData GetFrameworkCode GetMarcBiblio ); +use C4::Items qw( GetAnalyticsCount GetHostItemsInfo GetItemsInfo ); use C4::Circulation qw( GetTransfers ); use C4::Reserves; use C4::Serials qw( CountSubscriptionFromBiblionumber SearchSubscriptions GetLatestSerials ); use C4::XISBN qw( get_xisbns ); -use C4::External::Amazon; +use C4::External::Amazon qw( get_amazon_tld ); use C4::Search qw( z3950_search_args enabled_staff_search_views ); -use C4::Tags qw( get_tags get_tag ); +use C4::Tags qw( get_tags ); use C4::XSLT; -use Koha::DateUtils; +use Koha::DateUtils qw( format_sqldatetime ); use C4::HTML5Media; use C4::CourseReserves qw( GetItemCourseReservesInfo ); use C4::Acquisition qw(GetOrdersByBiblionumber); diff --git a/catalogue/export.pl b/catalogue/export.pl old mode 100755 new mode 100644 index ffde69cbcc2..5e6cff50cf1 --- a/catalogue/export.pl +++ b/catalogue/export.pl @@ -6,7 +6,7 @@ use C4::Auth qw( get_template_and_user ); use C4::Output; use C4::Biblio qw( GetMarcBiblio GetMarcControlnumber ); use CGI qw ( -utf8 ); -use C4::Ris; +use C4::Ris qw( marc2ris ); diff --git a/catalogue/getitem-ajax.pl b/catalogue/getitem-ajax.pl old mode 100755 new mode 100644 index ee8fe56a7bd..9dad680e0c5 --- a/catalogue/getitem-ajax.pl +++ b/catalogue/getitem-ajax.pl @@ -19,12 +19,10 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use JSON; +use JSON qw( to_json ); use C4::Auth qw( check_api_auth ); use C4::Biblio qw( GetMarcStructure ); -use C4::Items; -use C4::Koha; use C4::Output qw( output_with_http_headers ); use Koha::Libraries; diff --git a/catalogue/image.pl b/catalogue/image.pl old mode 100755 new mode 100644 diff --git a/catalogue/imageviewer.pl b/catalogue/imageviewer.pl old mode 100755 new mode 100644 index 5de5ed6b494..e9c43a3935e --- a/catalogue/imageviewer.pl +++ b/catalogue/imageviewer.pl @@ -21,7 +21,6 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Biblio; use C4::Items qw( GetItemsInfo ); use C4::Output qw( output_html_with_http_headers ); use C4::Search qw( enabled_staff_search_views ); diff --git a/catalogue/issuehistory.pl b/catalogue/issuehistory.pl old mode 100755 new mode 100644 index dc05b3ea175..8d17dc933af --- a/catalogue/issuehistory.pl +++ b/catalogue/issuehistory.pl @@ -22,7 +22,6 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Biblio; # GetBiblio use C4::Search qw( enabled_staff_search_views ); use C4::Serials qw( CountSubscriptionFromBiblionumber ); use Koha::Checkouts; diff --git a/catalogue/item-export.pl b/catalogue/item-export.pl old mode 100755 new mode 100644 index 0867376d302..4ca1d33acec --- a/catalogue/item-export.pl +++ b/catalogue/item-export.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output; diff --git a/catalogue/itemsearch.pl b/catalogue/itemsearch.pl old mode 100755 new mode 100644 index 54e3817d377..9b89e454fd3 --- a/catalogue/itemsearch.pl +++ b/catalogue/itemsearch.pl @@ -17,14 +17,13 @@ # along with Koha; if not, see . use Modern::Perl; -use CGI; +use CGI (); -use JSON; +use JSON qw( to_json ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_with_http_headers output_html_with_http_headers ); use C4::Items qw( SearchItems ); -use C4::Biblio; use C4::Koha qw( GetAuthorisedValues ); use Koha::AuthorisedValues; diff --git a/catalogue/labeledMARCdetail.pl b/catalogue/labeledMARCdetail.pl old mode 100755 new mode 100644 index f69fe65718f..5ae5b2c36b5 --- a/catalogue/labeledMARCdetail.pl +++ b/catalogue/labeledMARCdetail.pl @@ -19,13 +19,16 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use HTML::Entities; -use MARC::Record; +use HTML::Entities (); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::Biblio qw( GetFrameworkCode GetMarcBiblio GetMarcStructure GetBiblioData ); -use C4::Items qw( sub ); +use C4::Biblio qw( + GetBiblioData + GetFrameworkCode + GetMarcBiblio + GetMarcStructure +); use C4::Search qw( z3950_search_args enabled_staff_search_views ); use C4::Serials qw( CountSubscriptionFromBiblionumber ); diff --git a/catalogue/moredetail.pl b/catalogue/moredetail.pl old mode 100755 new mode 100644 index ad548bff864..7259a8d6d9d --- a/catalogue/moredetail.pl +++ b/catalogue/moredetail.pl @@ -22,9 +22,9 @@ use Modern::Perl; use C4::Koha qw( GetAuthorisedValues ); use CGI qw ( -utf8 ); -use HTML::Entities; +use HTML::Entities (); use C4::Biblio qw( GetBiblioData GetFrameworkCode GetMarcBiblio ); -use C4::Items qw( sub GetItemsInfo GetHostItemsInfo ); +use C4::Items qw( GetHostItemsInfo GetItemsInfo ); use C4::Acquisition; use C4::Output qw( output_and_exit output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); @@ -34,7 +34,6 @@ use C4::Search qw( enabled_staff_search_views z3950_search_args ); use Koha::Acquisition::Booksellers; use Koha::AuthorisedValues; use Koha::Biblios; -use Koha::DateUtils; use Koha::Items; use Koha::Patrons; diff --git a/catalogue/search-history.pl b/catalogue/search-history.pl old mode 100755 new mode 100644 diff --git a/catalogue/search.pl b/catalogue/search.pl old mode 100755 new mode 100644 index 1c8914f2671..323374db3f7 --- a/catalogue/search.pl +++ b/catalogue/search.pl @@ -143,10 +143,9 @@ use C4::Context; use C4::Output qw( output_html_with_http_headers pagination_bar ); use C4::Auth qw( get_template_and_user ); use C4::Search qw( searchResults enabled_staff_search_views z3950_search_args new_record_from_zebra ); -use C4::Languages qw( getlanguage getLanguages ); -use C4::Koha qw( getitemtypeimagelocation GetAuthorisedValues ); -use URI::Escape; -use POSIX qw(ceil floor); +use C4::Languages qw( getLanguages ); +use C4::Koha qw( GetAuthorisedValues getitemtypeimagelocation ); +use URI::Escape qw( uri_unescape ); use C4::Search qw( searchResults enabled_staff_search_views z3950_search_args new_record_from_zebra ); use Koha::ItemTypes; @@ -157,7 +156,7 @@ use Koha::SearchEngine::QueryBuilder; use Koha::Virtualshelves; use Koha::SearchFields; -use URI::Escape; +use URI::Escape qw( uri_unescape ); my $DisplayMultiPlaceHold = C4::Context->preference("DisplayMultiPlaceHold"); # create a new CGI object diff --git a/catalogue/showmarc.pl b/catalogue/showmarc.pl old mode 100755 new mode 100644 index 460d5b407f6..ccdd82f95a8 --- a/catalogue/showmarc.pl +++ b/catalogue/showmarc.pl @@ -24,8 +24,7 @@ use Modern::Perl; # standard or CPAN modules used use CGI qw(:standard -utf8); -use DBI; -use Encode; +use Encode (); # Koha modules used use C4::Context; diff --git a/catalogue/stockrotation.pl b/catalogue/stockrotation.pl old mode 100755 new mode 100644 index 27813c02e83..ba6ea230cf8 --- a/catalogue/stockrotation.pl +++ b/catalogue/stockrotation.pl @@ -25,7 +25,7 @@ =cut use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/catalogue/updateitem.pl b/catalogue/updateitem.pl old mode 100755 new mode 100644 index 708a42b4614..6d9022ff871 --- a/catalogue/updateitem.pl +++ b/catalogue/updateitem.pl @@ -21,8 +21,6 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( checkauth ); use C4::Context; -use C4::Biblio; -use C4::Items; use C4::Output; use C4::Circulation qw( LostItem ); use C4::Reserves; diff --git a/cataloguing/addbiblio.pl b/cataloguing/addbiblio.pl old mode 100755 new mode 100644 index badaf66d0f2..5f8119e9f2b --- a/cataloguing/addbiblio.pl +++ b/cataloguing/addbiblio.pl @@ -21,31 +21,40 @@ use Modern::Perl; -use CGI q(-utf8); +use CGI (); use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user haspermission ); -use C4::Biblio qw( GetMarcFromKohaField GetFrameworkCode GetMarcStructure GetUsedMarcStructure GetMarcBiblio PrepHostMarcField prepare_host_field TransformHtmlToMarc ModBiblio AddBiblio DelBiblio ); +use C4::Biblio qw( + AddBiblio + DelBiblio + GetFrameworkCode + GetMarcBiblio + GetMarcFromKohaField + GetMarcStructure + GetUsedMarcStructure + ModBiblio + prepare_host_field + PrepHostMarcField + TransformHtmlToMarc +); use C4::Search qw( FindDuplicate enabled_staff_search_views ); use C4::Auth qw( get_template_and_user haspermission ); use C4::Context; -use MARC::Record; -use C4::Log; -use C4::Koha; -use C4::ClassSource qw( GetClassSources GetClassSource ); +use MARC::Record (); +use C4::ClassSource qw( GetClassSources ); use C4::ImportBatch qw( sub GetImportRecordMarc ); use C4::Charset qw( SetMarcUnicodeFlag ); use Koha::BiblioFrameworks; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::ItemTypes; use Koha::Libraries; use Koha::BiblioFrameworks; -use Date::Calc qw(Today); use MARC::File::USMARC; use MARC::File::XML; -use URI::Escape; +use URI::Escape qw( uri_escape_utf8 ); if ( C4::Context->preference('marcflavour') eq 'UNIMARC' ) { MARC::File::XML->default_record_format('UNIMARC'); diff --git a/cataloguing/addbooks.pl b/cataloguing/addbooks.pl old mode 100755 new mode 100644 index 1deb5afa237..8c72e2d7cde --- a/cataloguing/addbooks.pl +++ b/cataloguing/addbooks.pl @@ -27,13 +27,11 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use URI::Escape; use C4::Auth qw( get_template_and_user ); -use C4::Biblio; use C4::Breeding qw( BreedingSearch ); use C4::Output qw( output_html_with_http_headers pagination_bar ); use C4::Koha qw( getnbpages ); -use C4::Languages qw( getlanguage ); +use C4::Languages (); use C4::Search qw( searchResults z3950_search_args ); use Koha::BiblioFrameworks; diff --git a/cataloguing/additem.pl b/cataloguing/additem.pl old mode 100755 new mode 100644 index 48b655a4de0..d3eda8f1ff4 --- a/cataloguing/additem.pl +++ b/cataloguing/additem.pl @@ -24,27 +24,37 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user haspermission ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); -use C4::Biblio qw( GetMarcFromKohaField GetFrameworkCode GetMarcStructure GetMarcBiblio TransformMarcToKoha TransformHtmlToXml ModBiblio EmbedItemsInMarcBiblio GetAuthorisedValueDesc IsMarcStructureInternal ); -use C4::Items qw( sub AddItemFromMarc GetMarcItem ModItemFromMarc ); +use C4::Biblio qw( + GetAuthorisedValueDesc + GetFrameworkCode + GetMarcBiblio + GetMarcFromKohaField + GetMarcStructure + IsMarcStructureInternal + ModBiblio + TransformHtmlToXml + TransformMarcToKoha +); +use C4::Items qw( AddItemFromMarc ModItemFromMarc ); use C4::Context; use C4::Circulation qw( LostItem ); use C4::Koha qw( GetAuthorisedValues ); -use C4::ClassSource qw( GetClassSources GetClassSource ); -use Koha::DateUtils; +use C4::ClassSource qw( GetClassSources ); +use Koha::DateUtils qw( dt_from_string ); use Koha::Items; use Koha::ItemTypes; use Koha::Libraries; use Koha::Patrons; use Koha::SearchEngine::Indexer; -use List::MoreUtils qw/any/; +use List::MoreUtils qw( any ); use C4::Search qw( enabled_staff_search_views ); -use Storable qw(thaw freeze); -use URI::Escape; +use Storable qw( freeze thaw ); +use URI::Escape qw( uri_escape_utf8 ); use C4::Members; use MARC::File::XML; -use URI::Escape; -use MIME::Base64 qw(decode_base64url encode_base64url); +use URI::Escape qw( uri_escape_utf8 ); +use MIME::Base64 qw( decode_base64url encode_base64url ); our $dbh = C4::Context->dbh; diff --git a/cataloguing/editor.pl b/cataloguing/editor.pl old mode 100755 new mode 100644 index 5fb2f0c0f70..93563892cb8 --- a/cataloguing/editor.pl +++ b/cataloguing/editor.pl @@ -20,11 +20,9 @@ use Modern::Perl; -use CGI; -use MARC::Record; +use CGI (); use C4::Auth qw( get_template_and_user ); -use C4::Biblio; use C4::Context; use C4::Output qw( output_html_with_http_headers ); use DBIx::Class::ResultClass::HashRefInflator; diff --git a/cataloguing/linkitem.pl b/cataloguing/linkitem.pl old mode 100755 new mode 100644 index 2bce8b0e700..15743cf736d --- a/cataloguing/linkitem.pl +++ b/cataloguing/linkitem.pl @@ -24,10 +24,8 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Biblio qw( GetMarcBiblio PrepHostMarcField ModBiblio ); -use C4::Items qw( sub ); +use C4::Biblio qw( GetMarcBiblio ModBiblio PrepHostMarcField ); use C4::Context; -use C4::Koha; my $query = CGI->new; diff --git a/cataloguing/merge.pl b/cataloguing/merge.pl old mode 100755 new mode 100644 index 57c53f13460..4dd8e88399d --- a/cataloguing/merge.pl +++ b/cataloguing/merge.pl @@ -23,10 +23,18 @@ use CGI qw ( -utf8 ); use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Items qw( sub MoveItemFromBiblio ); -use C4::Biblio qw( TransformHtmlToMarc GetMarcBiblio ModBiblio DelBiblio GetFrameworkCode GetMarcStructure GetMarcFromKohaField GetBiblioData ); +use C4::Items qw( MoveItemFromBiblio ); +use C4::Biblio qw( + DelBiblio + GetBiblioData + GetFrameworkCode + GetMarcBiblio + GetMarcFromKohaField + GetMarcStructure + ModBiblio + TransformHtmlToMarc +); use C4::Serials qw( CountSubscriptionFromBiblionumber ); -use C4::Koha; use C4::Reserves qw( MergeHolds ); use C4::Acquisition qw/ModOrder GetOrdersByBiblionumber/; diff --git a/cataloguing/merge_ajax.pl b/cataloguing/merge_ajax.pl old mode 100755 new mode 100644 index 1d1c8b147c7..6a76a45fb9f --- a/cataloguing/merge_ajax.pl +++ b/cataloguing/merge_ajax.pl @@ -4,7 +4,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); use CGI::Cookie; # need to check cookies before CGI parses the POST request -use JSON; +use JSON qw( encode_json ); use C4::Context; use C4::Biblio qw( GetMarcStructure ); diff --git a/cataloguing/moveitem.pl b/cataloguing/moveitem.pl old mode 100755 new mode 100644 index 285f09267ec..607a3593fba --- a/cataloguing/moveitem.pl +++ b/cataloguing/moveitem.pl @@ -24,16 +24,12 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Biblio; use C4::Items qw( MoveItemFromBiblio ); use C4::Context; -use C4::Koha; -use C4::ClassSource; use C4::Acquisition qw/GetOrderFromItemnumber ModOrder GetOrder/; use Koha::Biblios; -use Date::Calc qw(Today); use MARC::File::XML; diff --git a/cataloguing/plugin_launcher.pl b/cataloguing/plugin_launcher.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/EXAMPLE.pl b/cataloguing/value_builder/EXAMPLE.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/barcode.pl b/cataloguing/value_builder/barcode.pl old mode 100755 new mode 100644 index b03c23f4213..ba488980b92 --- a/cataloguing/value_builder/barcode.pl +++ b/cataloguing/value_builder/barcode.pl @@ -25,9 +25,9 @@ use Modern::Perl; use C4::Context; use C4::Barcodes::ValueBuilder; use C4::Biblio qw( GetMarcFromKohaField ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); -use Algorithm::CheckDigits; +use Algorithm::CheckDigits qw( CheckDigits ); my $DEBUG = 0; diff --git a/cataloguing/value_builder/barcode_manual.pl b/cataloguing/value_builder/barcode_manual.pl old mode 100755 new mode 100644 index c047fc58d96..b9ea0c2f6d9 --- a/cataloguing/value_builder/barcode_manual.pl +++ b/cataloguing/value_builder/barcode_manual.pl @@ -25,7 +25,7 @@ use Modern::Perl; use C4::Context; use C4::Barcodes::ValueBuilder; use C4::Biblio qw( GetMarcFromKohaField ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); my $DEBUG = 0; diff --git a/cataloguing/value_builder/callnumber-KU.pl b/cataloguing/value_builder/callnumber-KU.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/callnumber.pl b/cataloguing/value_builder/callnumber.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/cn_browser.pl b/cataloguing/value_builder/cn_browser.pl old mode 100755 new mode 100644 index ac89109fc1a..b4e54edd0e8 --- a/cataloguing/value_builder/cn_browser.pl +++ b/cataloguing/value_builder/cn_browser.pl @@ -20,7 +20,6 @@ # along with Koha; if not, see . use Modern::Perl; -use CGI; use C4::Auth qw( get_template_and_user ); use C4::ClassSource qw( GetClassSort ); diff --git a/cataloguing/value_builder/dateaccessioned.pl b/cataloguing/value_builder/dateaccessioned.pl old mode 100755 new mode 100644 index c88f65cc846..1ce91e55f6c --- a/cataloguing/value_builder/dateaccessioned.pl +++ b/cataloguing/value_builder/dateaccessioned.pl @@ -21,7 +21,7 @@ # along with Koha; if not, see . use Modern::Perl; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); my $builder = sub { my ( $params ) = @_; diff --git a/cataloguing/value_builder/macles.pl b/cataloguing/value_builder/macles.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/marc21_field_005.pl b/cataloguing/value_builder/marc21_field_005.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/marc21_field_006.pl b/cataloguing/value_builder/marc21_field_006.pl old mode 100755 new mode 100644 index 7853f09c2ae..fa055026d4e --- a/cataloguing/value_builder/marc21_field_006.pl +++ b/cataloguing/value_builder/marc21_field_006.pl @@ -27,7 +27,7 @@ use C4::Context; use C4::Search; use C4::Output qw( output_html_with_http_headers ); -use XML::LibXML; +use XML::LibXML (); my $builder = sub { my ( $params ) = @_; diff --git a/cataloguing/value_builder/marc21_field_007.pl b/cataloguing/value_builder/marc21_field_007.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/marc21_field_008.pl b/cataloguing/value_builder/marc21_field_008.pl old mode 100755 new mode 100644 index 46585aa874f..9b3b33cc855 --- a/cataloguing/value_builder/marc21_field_008.pl +++ b/cataloguing/value_builder/marc21_field_008.pl @@ -27,7 +27,7 @@ use C4::Context; use C4::Search; use C4::Output qw( output_html_with_http_headers ); -use XML::LibXML; +use XML::LibXML (); use Koha::Util::FrameworkPlugin qw|date_entered|; my $builder = sub { diff --git a/cataloguing/value_builder/marc21_field_008_authorities.pl b/cataloguing/value_builder/marc21_field_008_authorities.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/marc21_field_008_classifications.pl b/cataloguing/value_builder/marc21_field_008_classifications.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/marc21_field_245h.pl b/cataloguing/value_builder/marc21_field_245h.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/marc21_field_260b.pl b/cataloguing/value_builder/marc21_field_260b.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/marc21_leader.pl b/cataloguing/value_builder/marc21_leader.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/marc21_leader_authorities.pl b/cataloguing/value_builder/marc21_leader_authorities.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/marc21_linking_section.pl b/cataloguing/value_builder/marc21_linking_section.pl old mode 100755 new mode 100644 index 819b5f77662..4ab5fe10a14 --- a/cataloguing/value_builder/marc21_linking_section.pl +++ b/cataloguing/value_builder/marc21_linking_section.pl @@ -29,8 +29,6 @@ use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Biblio qw( GetMarcBiblio TransformMarcToKoha ); -use C4::Koha; -use MARC::Record; use Koha::ItemTypes; diff --git a/cataloguing/value_builder/marc21_orgcode.pl b/cataloguing/value_builder/marc21_orgcode.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/normarc_field_007.pl b/cataloguing/value_builder/normarc_field_007.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/normarc_field_008.pl b/cataloguing/value_builder/normarc_field_008.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/normarc_leader.pl b/cataloguing/value_builder/normarc_leader.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/stocknumber.pl b/cataloguing/value_builder/stocknumber.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/stocknumberAV.pl b/cataloguing/value_builder/stocknumberAV.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/stocknumberam123.pl b/cataloguing/value_builder/stocknumberam123.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_010.pl b/cataloguing/value_builder/unimarc_field_010.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_100.pl b/cataloguing/value_builder/unimarc_field_100.pl old mode 100755 new mode 100644 index 0e8804a8c75..b39b1e5aba2 --- a/cataloguing/value_builder/unimarc_field_100.pl +++ b/cataloguing/value_builder/unimarc_field_100.pl @@ -20,7 +20,7 @@ use Modern::Perl; -use Date::Calc qw( Today ); +use Date::Calc (); use Koha::Util::FrameworkPlugin qw(wrapper); use C4::Auth qw( get_template_and_user ); diff --git a/cataloguing/value_builder/unimarc_field_100_authorities.pl b/cataloguing/value_builder/unimarc_field_100_authorities.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_105.pl b/cataloguing/value_builder/unimarc_field_105.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_106.pl b/cataloguing/value_builder/unimarc_field_106.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_110.pl b/cataloguing/value_builder/unimarc_field_110.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_115a.pl b/cataloguing/value_builder/unimarc_field_115a.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_115b.pl b/cataloguing/value_builder/unimarc_field_115b.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_116.pl b/cataloguing/value_builder/unimarc_field_116.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_117.pl b/cataloguing/value_builder/unimarc_field_117.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_120.pl b/cataloguing/value_builder/unimarc_field_120.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_121a.pl b/cataloguing/value_builder/unimarc_field_121a.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_121b.pl b/cataloguing/value_builder/unimarc_field_121b.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_122.pl b/cataloguing/value_builder/unimarc_field_122.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_123a.pl b/cataloguing/value_builder/unimarc_field_123a.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_123d.pl b/cataloguing/value_builder/unimarc_field_123d.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_123e.pl b/cataloguing/value_builder/unimarc_field_123e.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_123f.pl b/cataloguing/value_builder/unimarc_field_123f.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_123g.pl b/cataloguing/value_builder/unimarc_field_123g.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_123i.pl b/cataloguing/value_builder/unimarc_field_123i.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_123j.pl b/cataloguing/value_builder/unimarc_field_123j.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_124.pl b/cataloguing/value_builder/unimarc_field_124.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_124a.pl b/cataloguing/value_builder/unimarc_field_124a.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_124b.pl b/cataloguing/value_builder/unimarc_field_124b.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_124c.pl b/cataloguing/value_builder/unimarc_field_124c.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_124d.pl b/cataloguing/value_builder/unimarc_field_124d.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_124e.pl b/cataloguing/value_builder/unimarc_field_124e.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_124f.pl b/cataloguing/value_builder/unimarc_field_124f.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_124g.pl b/cataloguing/value_builder/unimarc_field_124g.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_125.pl b/cataloguing/value_builder/unimarc_field_125.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_125a.pl b/cataloguing/value_builder/unimarc_field_125a.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_125b.pl b/cataloguing/value_builder/unimarc_field_125b.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_126.pl b/cataloguing/value_builder/unimarc_field_126.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_126a.pl b/cataloguing/value_builder/unimarc_field_126a.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_126b.pl b/cataloguing/value_builder/unimarc_field_126b.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_127.pl b/cataloguing/value_builder/unimarc_field_127.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_128a.pl b/cataloguing/value_builder/unimarc_field_128a.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_128b.pl b/cataloguing/value_builder/unimarc_field_128b.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_128c.pl b/cataloguing/value_builder/unimarc_field_128c.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_130.pl b/cataloguing/value_builder/unimarc_field_130.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_135a.pl b/cataloguing/value_builder/unimarc_field_135a.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_140.pl b/cataloguing/value_builder/unimarc_field_140.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_141.pl b/cataloguing/value_builder/unimarc_field_141.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_210c.pl b/cataloguing/value_builder/unimarc_field_210c.pl old mode 100755 new mode 100644 index fc976198353..3826ed2c219 --- a/cataloguing/value_builder/unimarc_field_210c.pl +++ b/cataloguing/value_builder/unimarc_field_210c.pl @@ -25,7 +25,6 @@ use C4::Context; use C4::Output qw( pagination_bar output_html_with_http_headers ); use CGI qw ( -utf8 ); use C4::Search; -use MARC::Record; use C4::Koha qw( getnbpages ); ###TODO To rewrite in order to use SearchAuthorities diff --git a/cataloguing/value_builder/unimarc_field_210c_bis.pl b/cataloguing/value_builder/unimarc_field_210c_bis.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_225a.pl b/cataloguing/value_builder/unimarc_field_225a.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_225a_bis.pl b/cataloguing/value_builder/unimarc_field_225a_bis.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_4XX.pl b/cataloguing/value_builder/unimarc_field_4XX.pl old mode 100755 new mode 100644 index 340b68d417c..fa5d0b16103 --- a/cataloguing/value_builder/unimarc_field_4XX.pl +++ b/cataloguing/value_builder/unimarc_field_4XX.pl @@ -29,8 +29,6 @@ use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Biblio qw( GetMarcBiblio TransformMarcToKoha ); -use C4::Koha; -use MARC::Record; use Koha::ItemTypes; diff --git a/cataloguing/value_builder/unimarc_field_686a.pl b/cataloguing/value_builder/unimarc_field_686a.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_field_700-4.pl b/cataloguing/value_builder/unimarc_field_700-4.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/unimarc_leader.pl b/cataloguing/value_builder/unimarc_leader.pl old mode 100755 new mode 100644 diff --git a/cataloguing/value_builder/upload.pl b/cataloguing/value_builder/upload.pl old mode 100755 new mode 100644 diff --git a/cataloguing/ysearch.pl b/cataloguing/ysearch.pl old mode 100755 new mode 100644 index 3a2f2f32572..87a9aaa0391 --- a/cataloguing/ysearch.pl +++ b/cataloguing/ysearch.pl @@ -29,7 +29,7 @@ use CGI qw ( -utf8 ); use C4::Context; use C4::Charset qw( nsb_clean ); use C4::Auth qw( check_cookie_auth ); -use JSON qw/ to_json /; +use JSON qw( to_json ); my $input = CGI->new; my $query = $input->param('term'); diff --git a/cataloguing/z3950_auth_search.pl b/cataloguing/z3950_auth_search.pl old mode 100755 new mode 100644 index 8295170caed..da93dac37f2 --- a/cataloguing/z3950_auth_search.pl +++ b/cataloguing/z3950_auth_search.pl @@ -24,7 +24,6 @@ use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Context; use C4::Breeding qw( Z3950Search Z3950SearchAuth ); -use C4::Koha; my $input = CGI->new; my $dbh = C4::Context->dbh; diff --git a/cataloguing/z3950_search.pl b/cataloguing/z3950_search.pl old mode 100755 new mode 100644 index fe3b596146e..8acc92c25d0 --- a/cataloguing/z3950_search.pl +++ b/cataloguing/z3950_search.pl @@ -25,7 +25,6 @@ use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Context; use C4::Breeding qw( Z3950Search ); -use C4::Koha; my $input = CGI->new; my $error = $input->param('error'); diff --git a/changelanguage.pl b/changelanguage.pl old mode 100755 new mode 100644 diff --git a/circ/add_message.pl b/circ/add_message.pl old mode 100755 new mode 100644 diff --git a/circ/article-request-slip.pl b/circ/article-request-slip.pl old mode 100755 new mode 100644 index e46161ab92b..ba2cfe192cb --- a/circ/article-request-slip.pl +++ b/circ/article-request-slip.pl @@ -24,7 +24,7 @@ use CGI qw( -utf8 ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Letters qw( GetPreparedLetter ); +use C4::Letters (); use Koha::ArticleRequests; use Koha::Patrons; diff --git a/circ/article-requests.pl b/circ/article-requests.pl old mode 100755 new mode 100644 diff --git a/circ/bookcount.pl b/circ/bookcount.pl old mode 100755 new mode 100644 index 1284a403656..9c1a63427a1 --- a/circ/bookcount.pl +++ b/circ/bookcount.pl @@ -22,14 +22,11 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use C4::Debug; use C4::Context; use C4::Circulation; use C4::Output qw( output_and_exit output_html_with_http_headers ); -use C4::Koha; use C4::Auth qw( get_template_and_user ); use Koha::Biblios; -use Koha::DateUtils; use Koha::Libraries; my $input = CGI->new; diff --git a/circ/branchoverdues.pl b/circ/branchoverdues.pl old mode 100755 new mode 100644 index fce85a7164d..c4a69a2334e --- a/circ/branchoverdues.pl +++ b/circ/branchoverdues.pl @@ -24,10 +24,10 @@ use C4::Auth qw( get_template_and_user ); use C4::Overdues qw( GetOverduesForBranch ); use C4::Biblio qw( GetMarcFromKohaField GetMarcStructure ); use C4::Koha qw( GetAuthorisedValues ); -use C4::Debug; -use Koha::DateUtils; +use C4::Debug qw( $debug ); +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::BiblioFrameworks; -use Data::Dumper; +use Data::Dumper qw( Dumper ); =head1 branchoverdues.pl diff --git a/circ/branchtransfers.pl b/circ/branchtransfers.pl old mode 100755 new mode 100644 index 7b802288b0d..905c38d5777 --- a/circ/branchtransfers.pl +++ b/circ/branchtransfers.pl @@ -25,10 +25,7 @@ use CGI qw ( -utf8 ); use C4::Circulation qw( transferbook ); use C4::Output qw( output_html_with_http_headers ); use C4::Reserves qw( ModReserve ModReserveAffect ); -use C4::Biblio; -use C4::Items; use C4::Auth qw( get_session get_template_and_user ); -use C4::Koha; use C4::Members; use Koha::BiblioFrameworks; use Koha::AuthorisedValues; diff --git a/circ/checkout-notes.pl b/circ/checkout-notes.pl old mode 100755 new mode 100644 diff --git a/circ/circulation-home.pl b/circ/circulation-home.pl old mode 100755 new mode 100644 diff --git a/circ/circulation.pl b/circ/circulation.pl old mode 100755 new mode 100644 index 8212aeecfed..a5d26b4533e --- a/circ/circulation.pl +++ b/circ/circulation.pl @@ -30,14 +30,13 @@ use DateTime; use DateTime::Duration; use Scalar::Util qw( looks_like_number ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); -use C4::Auth qw( get_session get_template_and_user haspermission ); +use C4::Auth qw( get_session get_template_and_user ); use C4::Koha; use C4::Circulation qw( barcodedecode CanBookBeIssued AddIssue ); use C4::Utils::DataTables::Members; use C4::Members; use C4::Biblio qw( TransformMarcToKoha ); use C4::Search qw( new_record_from_zebra ); -use MARC::Record; use C4::Reserves; use Koha::Holds; use C4::Context; @@ -45,8 +44,8 @@ use CGI::Session; use Koha::AuthorisedValues; use Koha::CsvProfiles; use Koha::Patrons; -use Koha::Patron::Debarments qw(GetDebarments); -use Koha::DateUtils; +use Koha::Patron::Debarments qw( GetDebarments ); +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Database; use Koha::BiblioFrameworks; use Koha::Items; @@ -55,12 +54,7 @@ use Koha::SearchEngine; use Koha::SearchEngine::Search; use Koha::Patron::Modifications; -use Date::Calc qw( - Today - Add_Delta_Days - Date_to_Days -); -use List::MoreUtils qw/uniq/; +use List::MoreUtils qw( uniq ); # # PARAMETERS READING diff --git a/circ/del_message.pl b/circ/del_message.pl old mode 100755 new mode 100644 diff --git a/circ/hold-transfer-slip.pl b/circ/hold-transfer-slip.pl old mode 100755 new mode 100644 diff --git a/circ/offline-mf.pl b/circ/offline-mf.pl old mode 100755 new mode 100644 diff --git a/circ/offline.pl b/circ/offline.pl old mode 100755 new mode 100644 diff --git a/circ/on-site_checkouts.pl b/circ/on-site_checkouts.pl old mode 100755 new mode 100644 index 493e99a449f..41e9a877bdd --- a/circ/on-site_checkouts.pl +++ b/circ/on-site_checkouts.pl @@ -21,7 +21,6 @@ use Modern::Perl; use C4::Auth qw( get_template_and_user ); use C4::Circulation qw( GetPendingOnSiteCheckouts ); use C4::Output qw( output_html_with_http_headers ); -use C4::Koha; use Koha::BiblioFrameworks; my $cgi = CGI->new; diff --git a/circ/overdue.pl b/circ/overdue.pl old mode 100755 new mode 100644 index 59f48a3dde7..272825dbc1c --- a/circ/overdue.pl +++ b/circ/overdue.pl @@ -24,9 +24,9 @@ use C4::Context; use C4::Output qw( output_html_with_http_headers ); use CGI qw(-oldstyle_urls -utf8); use C4::Auth qw( get_template_and_user ); -use C4::Debug; -use Text::CSV_XS; -use Koha::DateUtils; +use C4::Debug qw( $debug ); +use Text::CSV_XS (); +use Koha::DateUtils qw( dt_from_string output_pref ); use DateTime; use DateTime::Format::MySQL; diff --git a/circ/pendingreserves.pl b/circ/pendingreserves.pl old mode 100755 new mode 100644 index 64d2eb45f59..1832b8b5f90 --- a/circ/pendingreserves.pl +++ b/circ/pendingreserves.pl @@ -21,18 +21,17 @@ use Modern::Perl; use constant PULL_INTERVAL => 2; use List::MoreUtils qw( uniq ); -use YAML::XS; -use Encode; +use YAML::XS (); +use Encode (); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Debug; -use C4::Items qw( ModItemTransfer ); +use C4::Items (); use C4::Reserves qw( ModReserveCancelAll ); use Koha::Biblios; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::Holds; use DateTime::Duration; diff --git a/circ/renew.pl b/circ/renew.pl old mode 100755 new mode 100644 index 98fd20d3a53..383155416c4 --- a/circ/renew.pl +++ b/circ/renew.pl @@ -24,8 +24,7 @@ use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Circulation qw( barcodedecode CanBookBeRenewed GetSoonestRenewDate GetLatestAutoRenewDate AddRenewal ); -use C4::Koha; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Database; use Koha::BiblioFrameworks; diff --git a/circ/request-article.pl b/circ/request-article.pl old mode 100755 new mode 100644 diff --git a/circ/reserveratios.pl b/circ/reserveratios.pl old mode 100755 new mode 100644 index 56005da9982..b4ee960c8de --- a/circ/reserveratios.pl +++ b/circ/reserveratios.pl @@ -21,15 +21,14 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Date::Calc qw/Today Add_Delta_YM/; use POSIX qw( ceil ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Debug; +use C4::Debug qw( $debug ); use C4::Acquisition qw/GetOrdersByBiblionumber/; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Acquisition::Baskets; my $input = CGI->new; diff --git a/circ/returns.pl b/circ/returns.pl old mode 100755 new mode 100644 index 4032b8aa26f..8fee507d3d7 --- a/circ/returns.pl +++ b/circ/returns.pl @@ -38,11 +38,9 @@ use C4::Auth qw( get_template_and_user get_session haspermission ); use C4::Output qw( output_html_with_http_headers ); use C4::Circulation qw( barcodedecode updateWrongTransfer GetBranchItemRule AddReturn LostItem ); use C4::Reserves qw( ModReserve ModReserveAffect GetOtherReserves ); -use C4::Biblio; use C4::Circulation qw( barcodedecode updateWrongTransfer GetBranchItemRule AddReturn LostItem ); use C4::Context; -use C4::Items qw( ModItemTransfer sub ); -use C4::Koha; # FIXME : is it still useful ? +use C4::Items qw( ModItemTransfer ); use C4::Members::Messaging; use C4::Members; use C4::Output qw( output_html_with_http_headers ); @@ -52,7 +50,7 @@ use Koha::AuthorisedValues; use Koha::BiblioFrameworks; use Koha::Calendar; use Koha::Checkouts; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Holds; use Koha::Items; use Koha::Patrons; diff --git a/circ/set-library.pl b/circ/set-library.pl old mode 100755 new mode 100644 index 73faf7aeb0e..11d1c7edae3 --- a/circ/set-library.pl +++ b/circ/set-library.pl @@ -23,7 +23,6 @@ use CGI qw ( -utf8 ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user get_session ); -use C4::Koha; use Koha::BiblioFrameworks; use Koha::Cash::Registers; use Koha::Libraries; diff --git a/circ/transfer-slip.pl b/circ/transfer-slip.pl old mode 100755 new mode 100644 diff --git a/circ/transfers_to_send.pl b/circ/transfers_to_send.pl old mode 100755 new mode 100644 index 5e9fe3f6d69..d6974efdfc4 --- a/circ/transfers_to_send.pl +++ b/circ/transfers_to_send.pl @@ -23,7 +23,7 @@ use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); my $input = CGI->new; my $itemnumber = $input->param('itemnumber'); diff --git a/circ/transferstoreceive.pl b/circ/transferstoreceive.pl old mode 100755 new mode 100644 index 48355a53433..9184a2d6c8c --- a/circ/transferstoreceive.pl +++ b/circ/transferstoreceive.pl @@ -23,21 +23,15 @@ use CGI qw ( -utf8 ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Biblio; use C4::Circulation qw( GetTransfers GetTransfersFromTo ); use C4::Members; -use Date::Calc qw( - Today - Add_Delta_Days - Date_to_Days -); +use Date::Calc qw( Add_Delta_Days Date_to_Days Today ); -use C4::Koha; use C4::Reserves; use Koha::Items; use Koha::ItemTypes; use Koha::Libraries; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::BiblioFrameworks; use Koha::Patrons; diff --git a/circ/view_holdsqueue.pl b/circ/view_holdsqueue.pl old mode 100755 new mode 100644 index ce42af7f6c3..e519115d272 --- a/circ/view_holdsqueue.pl +++ b/circ/view_holdsqueue.pl @@ -26,8 +26,6 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Biblio; -use C4::Items; use C4::HoldsQueue qw( GetHoldsQueueItems ); use Koha::BiblioFrameworks; use Koha::ItemTypes; diff --git a/circ/waitingreserves.pl b/circ/waitingreserves.pl old mode 100755 new mode 100644 index aab2e36910f..63ea9c22284 --- a/circ/waitingreserves.pl +++ b/circ/waitingreserves.pl @@ -25,16 +25,10 @@ use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); use C4::Circulation; use C4::Members; -use C4::Biblio; -use C4::Items qw( sub ModItemTransfer ); -use Date::Calc qw( - Today - Add_Delta_Days - Date_to_Days -); +use C4::Items qw( ModItemTransfer ); +use Date::Calc qw( Date_to_Days Today ); use C4::Reserves qw( ModReserve ModReserveCancelAll ); -use C4::Koha; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::BiblioFrameworks; use Koha::Items; use Koha::ItemTypes; diff --git a/circ/ysearch.pl b/circ/ysearch.pl old mode 100755 new mode 100644 index 939188d7298..75f6f1dc61a --- a/circ/ysearch.pl +++ b/circ/ysearch.pl @@ -29,7 +29,7 @@ use CGI qw ( -utf8 ); use C4::Context; use C4::Auth qw( check_cookie_auth ); use Koha::Patrons; -use Koha::DateUtils qw/format_sqldatetime/; +use Koha::DateUtils qw( format_sqldatetime ); use JSON qw( to_json ); diff --git a/clubs/club-enrollments.pl b/clubs/club-enrollments.pl old mode 100755 new mode 100644 index 3eac228bb7a..09a5d2217a5 --- a/clubs/club-enrollments.pl +++ b/clubs/club-enrollments.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/clubs/clubs-add-modify.pl b/clubs/clubs-add-modify.pl old mode 100755 new mode 100644 index 264440166eb..d78e346c6fd --- a/clubs/clubs-add-modify.pl +++ b/clubs/clubs-add-modify.pl @@ -19,12 +19,12 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use Koha::Database; -use Koha::DateUtils qw(dt_from_string); +use Koha::DateUtils qw( dt_from_string ); use Koha::Clubs; use Koha::Club::Fields; diff --git a/clubs/clubs.pl b/clubs/clubs.pl old mode 100755 new mode 100644 index bb4dee6dccd..3bf8b49484f --- a/clubs/clubs.pl +++ b/clubs/clubs.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/clubs/patron-clubs-tab.pl b/clubs/patron-clubs-tab.pl old mode 100755 new mode 100644 index 1a12083e655..3a917ec8a88 --- a/clubs/patron-clubs-tab.pl +++ b/clubs/patron-clubs-tab.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/clubs/patron-enroll.pl b/clubs/patron-enroll.pl old mode 100755 new mode 100644 index 367b3c0f4b7..523a81d138c --- a/clubs/patron-enroll.pl +++ b/clubs/patron-enroll.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/clubs/templates-add-modify.pl b/clubs/templates-add-modify.pl old mode 100755 new mode 100644 index 5c966584ec2..137aa0fc5bf --- a/clubs/templates-add-modify.pl +++ b/clubs/templates-add-modify.pl @@ -19,12 +19,12 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use Koha::DateUtils qw(dt_from_string); +use Koha::DateUtils qw( dt_from_string ); use Koha::Club::Templates; use Koha::Club::Template::Fields; use Koha::Club::Template::EnrollmentFields; diff --git a/course_reserves/add_items.pl b/course_reserves/add_items.pl old mode 100755 new mode 100644 index a8de2068fd1..a0a406db318 --- a/course_reserves/add_items.pl +++ b/course_reserves/add_items.pl @@ -25,7 +25,6 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Koha qw( GetAuthorisedValues ); -use C4::Biblio; use Koha::Items; use C4::CourseReserves qw( GetCourse GetCourseReserve ModCourse ModCourseItem ModCourseReserve ); diff --git a/course_reserves/batch_add_items.pl b/course_reserves/batch_add_items.pl old mode 100755 new mode 100644 diff --git a/course_reserves/batch_rm_items.pl b/course_reserves/batch_rm_items.pl old mode 100755 new mode 100644 diff --git a/course_reserves/course-details.pl b/course_reserves/course-details.pl old mode 100755 new mode 100644 index ac1036daa21..e5c7efe5b29 --- a/course_reserves/course-details.pl +++ b/course_reserves/course-details.pl @@ -24,7 +24,6 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Koha; use C4::CourseReserves qw( DelCourse DelCourseReserve GetCourse GetCourseReserve GetCourseReserves ); diff --git a/course_reserves/course-reserves.pl b/course_reserves/course-reserves.pl old mode 100755 new mode 100644 diff --git a/course_reserves/course.pl b/course_reserves/course.pl old mode 100755 new mode 100644 diff --git a/course_reserves/mod_course.pl b/course_reserves/mod_course.pl old mode 100755 new mode 100644 diff --git a/docs/CAS/CASProxy/examples/koha_webservice.pl b/docs/CAS/CASProxy/examples/koha_webservice.pl old mode 100755 new mode 100644 diff --git a/docs/CAS/CASProxy/examples/proxy_cas.pl b/docs/CAS/CASProxy/examples/proxy_cas.pl old mode 100755 new mode 100644 diff --git a/docs/CAS/CASProxy/examples/proxy_cas_callback.pl b/docs/CAS/CASProxy/examples/proxy_cas_callback.pl old mode 100755 new mode 100644 index 9c6214795bf..75df85ffd65 --- a/docs/CAS/CASProxy/examples/proxy_cas_callback.pl +++ b/docs/CAS/CASProxy/examples/proxy_cas_callback.pl @@ -28,7 +28,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); use Authen::CAS::Client; -use Storable qw(nstore_fd); +use Storable qw( nstore_fd ); my $casServerUrl = 'https://localhost:8443/cas/'; my $cas = Authen::CAS::Client->new($casServerUrl); diff --git a/docs/CAS/CASProxy/examples/proxy_cas_data.pl b/docs/CAS/CASProxy/examples/proxy_cas_data.pl old mode 100755 new mode 100644 index 6346b5ec543..ed2e357acff --- a/docs/CAS/CASProxy/examples/proxy_cas_data.pl +++ b/docs/CAS/CASProxy/examples/proxy_cas_data.pl @@ -33,9 +33,8 @@ This PGTIOU will allow us to retrive the matching PGTID use Modern::Perl; use CGI qw ( -utf8 ); use Authen::CAS::Client; -use Storable qw(fd_retrieve); -use LWP::Simple; -use URI::Escape; +use Storable qw( fd_retrieve ); +use LWP::Simple qw( get ); my $casServerUrl = 'https://localhost:8443/cas/'; my $cas = Authen::CAS::Client->new($casServerUrl); diff --git a/errors/400.pl b/errors/400.pl old mode 100755 new mode 100644 index 33c262cc18f..647257fdffa --- a/errors/400.pl +++ b/errors/400.pl @@ -21,7 +21,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_with_http_headers ); use C4::Context; -use List::MoreUtils qw(any); +use List::MoreUtils qw( any ); my $query = CGI->new; my $admin = C4::Context->preference('KohaAdminEmailAddress'); diff --git a/errors/401.pl b/errors/401.pl old mode 100755 new mode 100644 index 1d2d54d533b..e2ba2a9342f --- a/errors/401.pl +++ b/errors/401.pl @@ -20,7 +20,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_with_http_headers ); use C4::Context; -use List::MoreUtils qw(any); +use List::MoreUtils qw( any ); my $query = CGI->new; my $admin = C4::Context->preference('KohaAdminEmailAddress'); diff --git a/errors/402.pl b/errors/402.pl old mode 100755 new mode 100644 index 9febcafa514..56feb466347 --- a/errors/402.pl +++ b/errors/402.pl @@ -21,7 +21,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_with_http_headers ); use C4::Context; -use List::MoreUtils qw(any); +use List::MoreUtils qw( any ); my $query = CGI->new; my $admin = C4::Context->preference('KohaAdminEmailAddress'); diff --git a/errors/403.pl b/errors/403.pl old mode 100755 new mode 100644 index fcf17702447..b43689b4224 --- a/errors/403.pl +++ b/errors/403.pl @@ -21,7 +21,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_with_http_headers ); use C4::Context; -use List::MoreUtils qw(any); +use List::MoreUtils qw( any ); my $query = CGI->new; my $admin = C4::Context->preference('KohaAdminEmailAddress'); diff --git a/errors/404.pl b/errors/404.pl old mode 100755 new mode 100644 index 51b8aa354a0..6e6fadfc8c5 --- a/errors/404.pl +++ b/errors/404.pl @@ -21,7 +21,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_with_http_headers ); use C4::Context; -use List::MoreUtils qw(any); +use List::MoreUtils qw( any ); my $query = CGI->new; my $admin = C4::Context->preference('KohaAdminEmailAddress'); diff --git a/errors/500.pl b/errors/500.pl old mode 100755 new mode 100644 index 1518862a878..80d402a395d --- a/errors/500.pl +++ b/errors/500.pl @@ -21,7 +21,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_with_http_headers ); use C4::Context; -use List::MoreUtils qw(any); +use List::MoreUtils qw( any ); my $query = CGI->new; my $admin = C4::Context->preference('KohaAdminEmailAddress'); diff --git a/help.pl b/help.pl old mode 100755 new mode 100644 diff --git a/ill/ill-requests.pl b/ill/ill-requests.pl old mode 100755 new mode 100644 index 9d35a471f94..e94b856eb10 --- a/ill/ill-requests.pl +++ b/ill/ill-requests.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); @@ -31,9 +31,9 @@ use Koha::Illrequest::Availability; use Koha::Libraries; use Koha::Token; -use Try::Tiny; -use URI::Escape; -use JSON; +use Try::Tiny qw( catch try ); +use URI::Escape qw( uri_escape_utf8 ); +use JSON qw( encode_json ); our $cgi = CGI->new; my $illRequests = Koha::Illrequests->new; diff --git a/installer/data/mysql/backfill_statistics.pl b/installer/data/mysql/backfill_statistics.pl old mode 100755 new mode 100644 index daa8e831ad9..f27cb41abe0 --- a/installer/data/mysql/backfill_statistics.pl +++ b/installer/data/mysql/backfill_statistics.pl @@ -6,14 +6,11 @@ use Modern::Perl; # CPAN modules -use DBI; -use Getopt::Long; # Koha modules use C4::Context; -use C4::Items; -use C4::Debug; -use Data::Dumper; +use C4::Debug qw( $debug ); +use Data::Dumper qw( Dumper ); use vars qw($debug $dbh); $dbh = C4::Context->dbh; diff --git a/installer/data/mysql/fix_unclosed_nonaccruing_fines_bug17135.pl b/installer/data/mysql/fix_unclosed_nonaccruing_fines_bug17135.pl old mode 100755 new mode 100644 index b3e4b06f372..b1fbdf6128e --- a/installer/data/mysql/fix_unclosed_nonaccruing_fines_bug17135.pl +++ b/installer/data/mysql/fix_unclosed_nonaccruing_fines_bug17135.pl @@ -22,11 +22,11 @@ use Modern::Perl; use C4::Context; use C4::Overdues qw/CalcFine/; -use C4::Log qw/logaction/; +use C4::Log qw( logaction ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Patrons; -use Getopt::Long; +use Getopt::Long qw( GetOptions ); my ($help, $verbose, $confirm, $log, $stdout_log); diff --git a/installer/data/mysql/labels_upgrade.pl b/installer/data/mysql/labels_upgrade.pl old mode 100755 new mode 100644 diff --git a/installer/data/mysql/patroncards_upgrade.pl b/installer/data/mysql/patroncards_upgrade.pl old mode 100755 new mode 100644 diff --git a/installer/data/mysql/update22to30.pl b/installer/data/mysql/update22to30.pl old mode 100755 new mode 100644 index 6a8a1ecd118..c5a183dae9d --- a/installer/data/mysql/update22to30.pl +++ b/installer/data/mysql/update22to30.pl @@ -14,12 +14,10 @@ use strict; # CPAN modules -use DBI; -use Getopt::Long; +use Getopt::Long qw( GetOptions ); # Koha modules use C4::Context; -use MARC::Record; use MARC::File::XML ( BinaryEncoding => 'utf8' ); # FIXME - The user might be installing a new database, so can't rely diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl old mode 100755 new mode 100644 index 6b0a6b53fe8..6ee7f84165d --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -32,20 +32,23 @@ use Modern::Perl; use feature 'say'; # CPAN modules -use DBI; -use Getopt::Long; +use Getopt::Long qw( GetOptions ); # Koha modules use C4::Context; -use C4::Installer; +use C4::Installer qw( + column_exists + foreign_key_exists + index_exists + TableExists +); use Koha::Database; use Koha; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); -use MARC::Record; use MARC::File::XML ( BinaryEncoding => 'utf8' ); -use File::Path qw[remove_tree]; # perl core module -use File::Slurp; +use File::Path qw( remove_tree ); # perl core module +use File::Slurp qw( read_file ); # FIXME - The user might be installing a new database, so can't rely # on /etc/koha.conf anyway. @@ -6079,7 +6082,7 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { push @gstrates, split ('\|', $gist_syspref); # we want to compare integer (or float) $_ = $_ + 0 for @gstrates; - use List::MoreUtils qw/uniq/; + use List::MoreUtils qw( uniq ); # remove duplicate values @gstrates = uniq sort @gstrates; my $new_syspref_value = join '|', @gstrates; diff --git a/installer/externalmodules.pl b/installer/externalmodules.pl old mode 100755 new mode 100644 diff --git a/installer/html-template-to-template-toolkit.pl b/installer/html-template-to-template-toolkit.pl old mode 100755 new mode 100644 index 2b9084b4b23..c1ad8a4917a --- a/installer/html-template-to-template-toolkit.pl +++ b/installer/html-template-to-template-toolkit.pl @@ -1,12 +1,10 @@ #!/usr/bin/perl use Modern::Perl; -use Carp; -use Data::Dumper; +use Carp qw( croak ); -use Getopt::Long; -use File::Basename; -use File::Copy; +use Getopt::Long qw( GetOptions ); +use File::Copy qw( copy ); my $help_msg = <new; diff --git a/labels/label-create-pdf.pl b/labels/label-create-pdf.pl old mode 100755 new mode 100644 index 8cac13d5332..c827f1c9365 --- a/labels/label-create-pdf.pl +++ b/labels/label-create-pdf.pl @@ -22,8 +22,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Debug; -use C4::Creators; +use C4::Creators (); use C4::Labels; my $cgi = CGI->new; diff --git a/labels/label-create-xml.pl b/labels/label-create-xml.pl old mode 100755 new mode 100644 index fe462a2a842..9bb0010ad01 --- a/labels/label-create-xml.pl +++ b/labels/label-create-xml.pl @@ -21,11 +21,8 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use XML::Simple; -use Data::Dumper; +use XML::Simple (); -use C4::Debug; -use C4::Creators; use C4::Labels; my $cgi = CGI->new; diff --git a/labels/label-edit-batch.pl b/labels/label-edit-batch.pl old mode 100755 new mode 100644 index a22e1a5474b..c4e436a8d59 --- a/labels/label-edit-batch.pl +++ b/labels/label-edit-batch.pl @@ -25,7 +25,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Creators; +use C4::Creators qw( get_label_summary html_table ); use C4::Labels; use Koha::Items; diff --git a/labels/label-edit-layout.pl b/labels/label-edit-layout.pl old mode 100755 new mode 100644 index 35c132e79d5..db580d258b0 --- a/labels/label-edit-layout.pl +++ b/labels/label-edit-layout.pl @@ -21,11 +21,16 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use POSIX; +use POSIX qw( exit sprintf ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Creators; +use C4::Creators qw( + get_barcode_types + get_font_types + get_label_types + get_text_justification_types +); use C4::Labels; my $cgi = CGI->new; diff --git a/labels/label-edit-profile.pl b/labels/label-edit-profile.pl old mode 100755 new mode 100644 index 3a156fa53ce..c9bbae63da1 --- a/labels/label-edit-profile.pl +++ b/labels/label-edit-profile.pl @@ -24,7 +24,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Creators; +use C4::Creators qw( get_all_templates get_unit_values ); use C4::Labels; my $cgi = CGI->new; diff --git a/labels/label-edit-range.pl b/labels/label-edit-range.pl old mode 100755 new mode 100644 diff --git a/labels/label-edit-template.pl b/labels/label-edit-template.pl old mode 100755 new mode 100644 index 75fe10f1de7..6199e9f8074 --- a/labels/label-edit-template.pl +++ b/labels/label-edit-template.pl @@ -24,7 +24,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Creators; +use C4::Creators qw( get_all_profiles get_unit_values ); use C4::Labels; my $cgi = CGI->new; diff --git a/labels/label-home.pl b/labels/label-home.pl old mode 100755 new mode 100644 diff --git a/labels/label-item-search.pl b/labels/label-item-search.pl old mode 100755 new mode 100644 index da74a0a5522..9d2c6aa9d15 --- a/labels/label-item-search.pl +++ b/labels/label-item-search.pl @@ -21,18 +21,17 @@ use Modern::Perl; use vars qw($debug $cgi_debug); use CGI qw ( -utf8 ); -use List::Util qw( max min ); -use POSIX qw(ceil); +use POSIX qw( ceil ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Context; use C4::Search qw( new_record_from_zebra ); use C4::Biblio qw( TransformMarcToKoha ); -use C4::Creators::Lib qw(html_table); -use C4::Debug; +use C4::Creators::Lib qw( html_table ); +use C4::Debug qw( $cgi_debug $debug ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Items; use Koha::ItemTypes; use Koha::SearchEngine::Search; diff --git a/labels/label-manage.pl b/labels/label-manage.pl old mode 100755 new mode 100644 index 3ae7ff1a56e..466c2eeec9e --- a/labels/label-manage.pl +++ b/labels/label-manage.pl @@ -23,11 +23,16 @@ use Modern::Perl; use vars qw($debug); use CGI qw ( -utf8 ); -use Data::Dumper; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Creators; +use C4::Creators qw( + get_all_layouts + get_all_profiles + get_all_templates + get_batch_summary + html_table +); use C4::Labels; my $cgi = CGI->new; diff --git a/labels/label-print.pl b/labels/label-print.pl old mode 100755 new mode 100644 index 0b9ec589e1d..568c3dde0e2 --- a/labels/label-print.pl +++ b/labels/label-print.pl @@ -20,12 +20,15 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Data::Dumper; use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Creators::Lib qw(get_all_templates get_all_layouts get_output_formats); +use C4::Creators::Lib qw( + get_all_layouts + get_all_templates + get_output_formats +); use C4::Labels::Batch; my $cgi = CGI->new; diff --git a/labels/spinelabel-home.pl b/labels/spinelabel-home.pl old mode 100755 new mode 100644 diff --git a/labels/spinelabel-print.pl b/labels/spinelabel-print.pl old mode 100755 new mode 100644 diff --git a/mainpage.pl b/mainpage.pl old mode 100755 new mode 100644 index 03ab38965b9..b81828a789f --- a/mainpage.pl +++ b/mainpage.pl @@ -23,8 +23,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; -use C4::NewsChannels; # GetNewsToDisplay +use C4::NewsChannels qw( GetNewsToDisplay ); # GetNewsToDisplay use C4::Tags qw( get_count_by_tag_status ); use Koha::Patron::Modifications; use Koha::Patron::Discharge; diff --git a/members/accountline-details.pl b/members/accountline-details.pl old mode 100755 new mode 100644 diff --git a/members/apikeys.pl b/members/apikeys.pl old mode 100755 new mode 100644 index f6fde368e4e..e054d6f87a0 --- a/members/apikeys.pl +++ b/members/apikeys.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit output_html_with_http_headers ); diff --git a/members/boraccount.pl b/members/boraccount.pl old mode 100755 new mode 100644 index 5ccb908ea1d..00caddb5728 --- a/members/boraccount.pl +++ b/members/boraccount.pl @@ -23,13 +23,11 @@ # along with Koha; if not, see . use Modern::Perl; -use URI::Escape; +use URI::Escape qw( uri_unescape ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use CGI qw ( -utf8 ); -use C4::Members; -use C4::Accounts; use Koha::Cash::Registers; use Koha::Patrons; use Koha::Patron::Categories; diff --git a/members/cancel-charge.pl b/members/cancel-charge.pl old mode 100755 new mode 100644 index 2f5ff42514c..30656d4f550 --- a/members/cancel-charge.pl +++ b/members/cancel-charge.pl @@ -17,7 +17,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( checkauth ); use Koha::Token; diff --git a/members/default_messageprefs.pl b/members/default_messageprefs.pl old mode 100755 new mode 100644 diff --git a/members/deletemem.pl b/members/deletemem.pl old mode 100755 new mode 100644 index e60b77b9fdd..fe6e1577f23 --- a/members/deletemem.pl +++ b/members/deletemem.pl @@ -25,12 +25,11 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Try::Tiny; +use Try::Tiny qw( catch try ); use C4::Context; use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use C4::Auth qw( get_template_and_user haspermission ); -use C4::Members; use C4::Suggestions qw( SearchSuggestion ); use Koha::Patrons; use Koha::Token; diff --git a/members/discharge.pl b/members/discharge.pl old mode 100755 new mode 100644 index 699c4bd87b1..6a8d335475f --- a/members/discharge.pl +++ b/members/discharge.pl @@ -28,18 +28,15 @@ Allows librarian to edit and/or manage borrowers' discharges =cut use Modern::Perl; -use Carp; +use Carp qw( carp ); use CGI qw( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); -use C4::Members; use C4::Reserves; -use C4::Letters; use Koha::Patron::Discharge; use Koha::Patrons; -use Koha::DateUtils; my $input = CGI->new; diff --git a/members/discharges.pl b/members/discharges.pl old mode 100755 new mode 100644 index 574f3d9d5e6..7f7fdcbcb65 --- a/members/discharges.pl +++ b/members/discharges.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use C4::Context; diff --git a/members/files.pl b/members/files.pl old mode 100755 new mode 100644 index 92231761402..91f9d4ba676 --- a/members/files.pl +++ b/members/files.pl @@ -24,9 +24,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use C4::Members; -use C4::Debug; -use Koha::DateUtils; use Koha::Patrons; use Koha::Patron::Files; use Koha::Patron::Categories; diff --git a/members/guarantor_search.pl b/members/guarantor_search.pl old mode 100755 new mode 100644 diff --git a/members/holdshistory.pl b/members/holdshistory.pl old mode 100755 new mode 100644 diff --git a/members/housebound.pl b/members/housebound.pl old mode 100755 new mode 100644 index c8af38342e9..bb686b0a0a8 --- a/members/housebound.pl +++ b/members/housebound.pl @@ -25,12 +25,12 @@ =cut use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use DateTime; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::Libraries; use Koha::Patrons; use Koha::Patron::Categories; diff --git a/members/ill-requests.pl b/members/ill-requests.pl old mode 100755 new mode 100644 diff --git a/members/mancredit.pl b/members/mancredit.pl old mode 100755 new mode 100644 index 2317b6b6f89..943230b15aa --- a/members/mancredit.pl +++ b/members/mancredit.pl @@ -29,7 +29,6 @@ use CGI qw ( -utf8 ); use C4::Members; use C4::Accounts; -use C4::Items; use Koha::Items; use Koha::Patrons; diff --git a/members/maninvoice.pl b/members/maninvoice.pl old mode 100755 new mode 100644 index e6b98a47769..fff99b923b4 --- a/members/maninvoice.pl +++ b/members/maninvoice.pl @@ -23,14 +23,13 @@ # along with Koha; if not, see . use Modern::Perl; -use Try::Tiny; +use Try::Tiny qw( catch try ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use CGI qw ( -utf8 ); use C4::Members; use C4::Accounts; -use C4::Items; use Koha::Token; use Koha::Patrons; diff --git a/members/member-flags.pl b/members/member-flags.pl old mode 100755 new mode 100644 diff --git a/members/member-password.pl b/members/member-password.pl old mode 100755 new mode 100644 index 0229e85caa3..aebe821b933 --- a/members/member-password.pl +++ b/members/member-password.pl @@ -7,19 +7,17 @@ use Modern::Perl; use C4::Auth qw( get_template_and_user ); -use Koha::AuthUtils; use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use C4::Context; use C4::Members; use C4::Circulation; use CGI qw ( -utf8 ); -use Koha::AuthUtils; use Koha::Token; use Koha::Patrons; use Koha::Patron::Categories; -use Try::Tiny; +use Try::Tiny qw( catch try ); my $input = CGI->new; diff --git a/members/member.pl b/members/member.pl old mode 100755 new mode 100644 index 9dee72b4b71..4b4578cf479 --- a/members/member.pl +++ b/members/member.pl @@ -27,8 +27,7 @@ use Modern::Perl; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use CGI qw( -utf8 ); -use Koha::DateUtils; -use Koha::List::Patron; +use Koha::List::Patron qw( GetPatronLists ); use Koha::Patrons; my $input = CGI->new; diff --git a/members/memberentry.pl b/members/memberentry.pl old mode 100755 new mode 100644 index e7aafd257db..3584c61841f --- a/members/memberentry.pl +++ b/members/memberentry.pl @@ -23,7 +23,6 @@ use Modern::Perl; # external modules use CGI qw ( -utf8 ); -use List::MoreUtils qw/uniq/; # internal modules use C4::Auth qw( get_template_and_user haspermission ); @@ -31,14 +30,13 @@ use C4::Context; use C4::Output qw( output_and_exit output_and_exit_if_error output_html_with_http_headers ); use C4::Members qw( checkcardnumber get_cardnumber_length ); use C4::Koha qw( GetAuthorisedValues ); -use C4::Log; use C4::Letters qw( SendAlerts ); use C4::Form::MessagingPreferences; -use Koha::AuthUtils qw( is_password_valid ); +use Koha::AuthUtils (); use Koha::AuthorisedValues; -use Koha::Patron::Debarments; +use Koha::Patron::Debarments qw( AddDebarment DelDebarment GetDebarments ); use Koha::Cities; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Libraries; use Koha::Patrons; use Koha::Patron::Attribute::Types; diff --git a/members/members-home.pl b/members/members-home.pl old mode 100755 new mode 100644 index c6522c03482..509a32aa56f --- a/members/members-home.pl +++ b/members/members-home.pl @@ -25,7 +25,7 @@ use C4::Context; use C4::Members; use Koha::Patron::Modifications; use Koha::Libraries; -use Koha::List::Patron; +use Koha::List::Patron qw( GetPatronLists ); use Koha::Patron::Categories; my $query = CGI->new; diff --git a/members/members-update-do.pl b/members/members-update-do.pl old mode 100755 new mode 100644 diff --git a/members/members-update.pl b/members/members-update.pl old mode 100755 new mode 100644 diff --git a/members/merge-patrons.pl b/members/merge-patrons.pl old mode 100755 new mode 100644 index bc26d96c83f..5318ff6ff5f --- a/members/merge-patrons.pl +++ b/members/merge-patrons.pl @@ -19,7 +19,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Try::Tiny; +use Try::Tiny qw( catch try ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/members/mod_debarment.pl b/members/mod_debarment.pl old mode 100755 new mode 100644 index 622c5c83ad8..977cb2fddd7 --- a/members/mod_debarment.pl +++ b/members/mod_debarment.pl @@ -22,8 +22,8 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( checkauth ); -use Koha::DateUtils; -use Koha::Patron::Debarments; +use Koha::DateUtils qw( dt_from_string ); +use Koha::Patron::Debarments qw( AddDebarment DelDebarment ); my $cgi = CGI->new; diff --git a/members/moremember.pl b/members/moremember.pl old mode 100755 new mode 100644 index 3f0f937fb14..e19bc201503 --- a/members/moremember.pl +++ b/members/moremember.pl @@ -33,11 +33,10 @@ use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use C4::Form::MessagingPreferences; -use List::MoreUtils qw/uniq/; +use List::MoreUtils qw( uniq ); use Koha::Patron::Attribute::Types; -use Koha::Patron::Debarments qw(GetDebarments); +use Koha::Patron::Debarments qw( GetDebarments ); use Koha::Patron::Messages; -use Koha::DateUtils; use Koha::CsvProfiles; use Koha::Patrons; use Koha::Patron::Files; diff --git a/members/notices.pl b/members/notices.pl old mode 100755 new mode 100644 index ebe47c13b43..821b738ea78 --- a/members/notices.pl +++ b/members/notices.pl @@ -24,7 +24,7 @@ use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use CGI qw ( -utf8 ); use C4::Members; -use C4::Letters qw( GetMessage ResendMessage GetQueuedMessages ); +use C4::Letters (); use Koha::Patrons; use Koha::Patron::Categories; diff --git a/members/patronimage.pl b/members/patronimage.pl old mode 100755 new mode 100644 diff --git a/members/pay.pl b/members/pay.pl old mode 100755 new mode 100644 index b15a2706916..1493ad07a94 --- a/members/pay.pl +++ b/members/pay.pl @@ -28,21 +28,16 @@ use Modern::Perl; -use URI::Escape; +use URI::Escape qw( uri_escape_utf8 uri_unescape ); use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use CGI qw ( -utf8 ); -use C4::Members; -use C4::Accounts; -use C4::Stats; -use C4::Koha; -use C4::Overdues; use Koha::Patrons; use Koha::Items; use Koha::Patron::Categories; -use URI::Escape; +use URI::Escape qw( uri_escape_utf8 uri_unescape ); our $input = CGI->new; diff --git a/members/paycollect.pl b/members/paycollect.pl old mode 100755 new mode 100644 index 97695fb4542..19ac667c07f --- a/members/paycollect.pl +++ b/members/paycollect.pl @@ -18,15 +18,12 @@ # along with Koha; if not, see . use Modern::Perl; -use URI::Escape; +use URI::Escape qw( uri_escape uri_unescape ); use CGI qw ( -utf8 ); use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); -use C4::Members; -use C4::Accounts; -use C4::Koha; use Koha::Cash::Registers; use Koha::Patrons; @@ -34,7 +31,7 @@ use Koha::Patron::Categories; use Koha::AuthorisedValues; use Koha::Account; use Koha::Token; -use Koha::DateUtils; +use Koha::DateUtils qw( output_pref ); my $input = CGI->new(); diff --git a/members/print_overdues.pl b/members/print_overdues.pl old mode 100755 new mode 100644 index 897e084ba9e..2583d6ba87b --- a/members/print_overdues.pl +++ b/members/print_overdues.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Context; use C4::Auth qw( get_template_and_user ); diff --git a/members/printfeercpt.pl b/members/printfeercpt.pl old mode 100755 new mode 100644 index 1060318291f..154814e195e --- a/members/printfeercpt.pl +++ b/members/printfeercpt.pl @@ -23,7 +23,7 @@ use Modern::Perl; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use CGI qw ( -utf8 ); -use C4::Letters qw( GetPreparedLetter ); +use C4::Letters (); use Koha::Account::Lines; my $input = CGI->new; diff --git a/members/printinvoice.pl b/members/printinvoice.pl old mode 100755 new mode 100644 index 94844133c22..8ee352d0b77 --- a/members/printinvoice.pl +++ b/members/printinvoice.pl @@ -23,7 +23,7 @@ use Modern::Perl; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use CGI qw ( -utf8 ); -use C4::Letters qw( GetPreparedLetter ); +use C4::Letters (); use Koha::Account::Lines; my $input = CGI->new; diff --git a/members/printslip.pl b/members/printslip.pl old mode 100755 new mode 100644 index 71d0541ce14..cd5c3df20d2 --- a/members/printslip.pl +++ b/members/printslip.pl @@ -38,8 +38,6 @@ use C4::Context; use C4::Auth qw( get_session get_template_and_user ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use C4::Members qw( IssueSlip ); -use C4::Koha; -use Koha::DateUtils; #use Smart::Comments; #use Data::Dumper; diff --git a/members/purchase-suggestions.pl b/members/purchase-suggestions.pl old mode 100755 new mode 100644 diff --git a/members/readingrec.pl b/members/readingrec.pl old mode 100755 new mode 100644 index 09b5327056d..fc4172829d1 --- a/members/readingrec.pl +++ b/members/readingrec.pl @@ -27,8 +27,8 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use C4::Members qw( GetAllIssues ); -use List::MoreUtils qw/any uniq/; -use Koha::DateUtils; +use List::MoreUtils qw( uniq ); +use Koha::DateUtils qw( dt_from_string ); use Koha::Patrons; use Koha::Patron::Categories; diff --git a/members/routing-lists.pl b/members/routing-lists.pl old mode 100755 new mode 100644 diff --git a/members/setstatus.pl b/members/setstatus.pl old mode 100755 new mode 100644 index be36e600269..0e14509399e --- a/members/setstatus.pl +++ b/members/setstatus.pl @@ -28,7 +28,6 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Context; use C4::Members; -use C4::Auth qw( checkauth ); use Koha::Patrons; diff --git a/members/statistics.pl b/members/statistics.pl old mode 100755 new mode 100644 index a7b0d9847a5..2d7ae2ba26f --- a/members/statistics.pl +++ b/members/statistics.pl @@ -28,7 +28,11 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Members; -use C4::Members::Statistics qw( get_fields GetPrecedentStateByBorrower GetTotalIssuesTodayByBorrower GetTotalIssuesReturnedTodayByBorrower ); +use C4::Members::Statistics qw( + GetPrecedentStateByBorrower + GetTotalIssuesReturnedTodayByBorrower + GetTotalIssuesTodayByBorrower +); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use Koha::Patrons; use Koha::Patron::Categories; diff --git a/members/summary-print.pl b/members/summary-print.pl old mode 100755 new mode 100644 index 0de51dfd3cd..ad66a55e785 --- a/members/summary-print.pl +++ b/members/summary-print.pl @@ -17,15 +17,14 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use C4::Members; use C4::Circulation qw( GetIssuingCharges ); use C4::Reserves; -use C4::Items qw( sub ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::Holds; use Koha::ItemTypes; use Koha::Patrons; diff --git a/members/update-child.pl b/members/update-child.pl old mode 100755 new mode 100644 diff --git a/misc/add_date_fields_to_marc_records.pl b/misc/add_date_fields_to_marc_records.pl old mode 100755 new mode 100644 index 024a40c0e68..a22505ca831 --- a/misc/add_date_fields_to_marc_records.pl +++ b/misc/add_date_fields_to_marc_records.pl @@ -18,17 +18,16 @@ use Modern::Perl; BEGIN { - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script; -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use MARC::Field; -use C4::Biblio qw( GetMarcBiblio ModBiblio ); +use C4::Biblio (); use Koha::DateUtils qw( dt_from_string ); my ( $verbose, $help, $confirm, $where, @fields, $unless_exists_field ); diff --git a/misc/admin/set_password.pl b/misc/admin/set_password.pl old mode 100755 new mode 100644 index 09151435038..44e9cc593e5 --- a/misc/admin/set_password.pl +++ b/misc/admin/set_password.pl @@ -19,10 +19,10 @@ use Modern::Perl; -use Bytes::Random::Secure; -use Getopt::Long; -use Pod::Usage; -use String::Random; +use Bytes::Random::Secure (); +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); +use String::Random (); use Koha::Patrons; use Koha::Script; diff --git a/misc/background_jobs_worker.pl b/misc/background_jobs_worker.pl old mode 100755 new mode 100644 index 5d409cdf1b7..79872898954 --- a/misc/background_jobs_worker.pl +++ b/misc/background_jobs_worker.pl @@ -16,8 +16,8 @@ # along with Koha; if not, see . use Modern::Perl; -use JSON qw( encode_json decode_json ); -use Try::Tiny; +use JSON qw( decode_json ); +use Try::Tiny qw( catch try ); use Koha::BackgroundJobs; diff --git a/misc/batchCompareMARCvsFrameworks.pl b/misc/batchCompareMARCvsFrameworks.pl old mode 100755 new mode 100644 index af8a66796ef..78d1e44b2de --- a/misc/batchCompareMARCvsFrameworks.pl +++ b/misc/batchCompareMARCvsFrameworks.pl @@ -7,19 +7,17 @@ use strict; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/kohalib.pl" }; + eval { require "$FindBin::Bin/kohalib.pl" }; } # Koha modules used use Koha::Script; use C4::Context; use MARC::File::USMARC; -use MARC::Record; use MARC::Batch; -use Getopt::Long; -use IO::File; +use Getopt::Long qw( GetOptions ); +use IO::File (); my ( $input_marc_file,$number,$nowarning,$frameworkcode) = ('',0); my $version; diff --git a/misc/batchDeleteUnusedSubfields.pl b/misc/batchDeleteUnusedSubfields.pl old mode 100755 new mode 100644 index e43d914e710..0498bed0b6f --- a/misc/batchDeleteUnusedSubfields.pl +++ b/misc/batchDeleteUnusedSubfields.pl @@ -6,18 +6,16 @@ use strict; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/kohalib.pl" }; + eval { require "$FindBin::Bin/kohalib.pl" }; } # Koha modules used use Koha::Script; -use MARC::Record; use C4::Context; use C4::Biblio qw( GetMarcStructure ); -use Time::HiRes qw(gettimeofday); +use Time::HiRes qw( gettimeofday ); -use Getopt::Long; +use Getopt::Long qw( GetOptions ); my ( $input_marc_file, $number) = ('',0); my ($version, $confirm,$test_parameter); GetOptions( diff --git a/misc/batchImportMARCWithBiblionumbers.pl b/misc/batchImportMARCWithBiblionumbers.pl old mode 100755 new mode 100644 index 6a7329a66d6..6c8e4db9ff3 --- a/misc/batchImportMARCWithBiblionumbers.pl +++ b/misc/batchImportMARCWithBiblionumbers.pl @@ -6,8 +6,7 @@ use strict; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/kohalib.pl" }; + eval { require "$FindBin::Bin/kohalib.pl" }; } # Koha modules used @@ -15,13 +14,12 @@ BEGIN { use Koha::Script; use C4::Context; use C4::Biblio qw( GetMarcFromKohaField ); -use MARC::Record; use MARC::File::USMARC; use MARC::File::XML; use MARC::Batch; -use Time::HiRes qw(gettimeofday); -use Getopt::Long; -use IO::File; +use Time::HiRes qw( gettimeofday ); +use Getopt::Long qw( GetOptions ); +use IO::File (); my $input_marc_file = ''; my ($version); diff --git a/misc/batchRebuildBiblioTables.pl b/misc/batchRebuildBiblioTables.pl old mode 100755 new mode 100644 index 50a6cfc89ad..6adf95deb14 --- a/misc/batchRebuildBiblioTables.pl +++ b/misc/batchRebuildBiblioTables.pl @@ -8,19 +8,23 @@ use strict; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/kohalib.pl" }; + eval { require "$FindBin::Bin/kohalib.pl" }; } # Koha modules used use Koha::Script; -use MARC::Record; -use C4::Charset qw( StripNonXmlChars ); +use MARC::Record (); +use C4::Charset (); use C4::Context; -use C4::Biblio qw( GetXmlBiblio TransformMarcToKoha _koha_modify_biblio _koha_modify_biblioitem_nonmarc ); -use Time::HiRes qw(gettimeofday); +use C4::Biblio qw( + _koha_modify_biblio + _koha_modify_biblioitem_nonmarc + GetXmlBiblio + TransformMarcToKoha +); +use Time::HiRes qw( gettimeofday ); -use Getopt::Long; +use Getopt::Long qw( GetOptions ); my ($version, $confirm); GetOptions( diff --git a/misc/batchRebuildItemsTables.pl b/misc/batchRebuildItemsTables.pl old mode 100755 new mode 100644 index a0d59ddd3f2..b7aca13b13d --- a/misc/batchRebuildItemsTables.pl +++ b/misc/batchRebuildItemsTables.pl @@ -2,16 +2,16 @@ use Modern::Perl; -use Getopt::Long; +use Getopt::Long qw( GetOptions ); use MARC::Field; -use MARC::Record; -use Pod::Usage; -use Time::HiRes qw(gettimeofday); +use MARC::Record (); +use Pod::Usage qw( pod2usage ); +use Time::HiRes qw( gettimeofday ); use Koha::Script; use C4::Context; -use C4::Biblio qw( GetMarcFromKohaField GetMarcBiblio ); -use C4::Items qw( sub ModItemFromMarc ); +use C4::Biblio qw( GetMarcBiblio GetMarcFromKohaField ); +use C4::Items qw( ModItemFromMarc ); =head1 NAME diff --git a/misc/batchRepairMissingBiblionumbers.pl b/misc/batchRepairMissingBiblionumbers.pl old mode 100755 new mode 100644 index 781a80571f4..adbfbd7f07e --- a/misc/batchRepairMissingBiblionumbers.pl +++ b/misc/batchRepairMissingBiblionumbers.pl @@ -7,14 +7,13 @@ use warnings; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/kohalib.pl" }; + eval { require "$FindBin::Bin/kohalib.pl" }; } # Koha modules used use Koha::Script; use C4::Context; -use C4::Biblio qw( GetMarcBiblio _koha_marc_update_bib_ids ModBiblio ModBiblioMarc ); +use C4::Biblio qw( _koha_marc_update_bib_ids GetMarcBiblio ModBiblioMarc ); my $dbh = C4::Context->dbh; diff --git a/misc/batchdeletebiblios.pl b/misc/batchdeletebiblios.pl old mode 100755 new mode 100644 index 289fb855359..0abe2b41063 --- a/misc/batchdeletebiblios.pl +++ b/misc/batchdeletebiblios.pl @@ -1,9 +1,8 @@ #!/usr/bin/perl use Modern::Perl; -use Getopt::Long; -use Pod::Usage; -use IO::File; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Script; use C4::Biblio qw( DelBiblio ); diff --git a/misc/bin/clear_cache.pl b/misc/bin/clear_cache.pl old mode 100755 new mode 100644 diff --git a/misc/bin/connexion_import_daemon.pl b/misc/bin/connexion_import_daemon.pl old mode 100755 new mode 100644 index 22407eb2a83..dabf7108b7b --- a/misc/bin/connexion_import_daemon.pl +++ b/misc/bin/connexion_import_daemon.pl @@ -20,7 +20,7 @@ use strict; use warnings; -use Getopt::Long; +use Getopt::Long qw( GetOptions ); my ($help, $config, $daemon); @@ -81,18 +81,18 @@ exit; { package ImportProxyServer; -use Carp; -use IO::Socket::INET; +use Carp qw( croak ); +use IO::Socket::INET qw( SOCK_STREAM ); # use IO::Socket::IP; use IO::Select; -use POSIX; +use POSIX qw( close exit fork localtime open printf sprintf ); use HTTP::Status qw(:constants); use strict; use warnings; -use LWP::UserAgent; -use XML::Simple; -use MARC::Record; +use LWP::UserAgent (); +use XML::Simple qw( XMLin ); +use MARC::Record (); use MARC::File::XML; use constant CLIENT_READ_TIMEOUT => 5; diff --git a/misc/check_sysprefs.pl b/misc/check_sysprefs.pl old mode 100755 new mode 100644 index 942d8f27c46..aed792c9adb --- a/misc/check_sysprefs.pl +++ b/misc/check_sysprefs.pl @@ -8,7 +8,7 @@ use strict; use warnings; -use File::Find; +use File::Find qw( find ); use Koha::Script; use C4::Context; diff --git a/misc/commit_file.pl b/misc/commit_file.pl old mode 100755 new mode 100644 index 5b4b53186fb..86d76bfaa50 --- a/misc/commit_file.pl +++ b/misc/commit_file.pl @@ -5,14 +5,13 @@ use warnings; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/kohalib.pl" }; + eval { require "$FindBin::Bin/kohalib.pl" }; } use Koha::Script; use C4::Context; use C4::ImportBatch qw( GetImportBatch sub BatchCommitRecords BatchRevertRecords ); -use Getopt::Long; +use Getopt::Long qw( GetOptions ); $| = 1; diff --git a/misc/cronjobs/advance_notices.pl b/misc/cronjobs/advance_notices.pl old mode 100755 new mode 100644 index 3fc18ac99bf..da7ceb86bd0 --- a/misc/cronjobs/advance_notices.pl +++ b/misc/cronjobs/advance_notices.pl @@ -38,24 +38,20 @@ the OPAC. use strict; use warnings; -use Getopt::Long; -use Pod::Usage; -use Data::Dumper; +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" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script -cron; -use C4::Biblio; use C4::Context; use C4::Letters qw( get_item_content EnqueueLetter GetPreparedLetter ); use C4::Members; use C4::Members::Messaging; use C4::Overdues; -use Koha::DateUtils; -use C4::Log; +use C4::Log qw( cronlogaction ); use Koha::Items; use Koha::Libraries; use Koha::Patrons; diff --git a/misc/cronjobs/archive_purchase_suggestions.pl b/misc/cronjobs/archive_purchase_suggestions.pl old mode 100755 new mode 100644 index 02e68808e06..a7c3e8879c3 --- a/misc/cronjobs/archive_purchase_suggestions.pl +++ b/misc/cronjobs/archive_purchase_suggestions.pl @@ -2,8 +2,8 @@ use Modern::Perl; -use Pod::Usage; -use Getopt::Long; +use Pod::Usage qw( pod2usage ); +use Getopt::Long qw( GetOptions ); use Koha::Script -cron; diff --git a/misc/cronjobs/automatic_checkin.pl b/misc/cronjobs/automatic_checkin.pl old mode 100755 new mode 100644 index 4eff2d5083f..2960b4a83dd --- a/misc/cronjobs/automatic_checkin.pl +++ b/misc/cronjobs/automatic_checkin.pl @@ -20,7 +20,7 @@ use Modern::Perl; use Koha::Checkouts; use Koha::Script -cron; -use C4::Log; +use C4::Log qw( cronlogaction ); cronlogaction(); diff --git a/misc/cronjobs/automatic_item_modification_by_age.pl b/misc/cronjobs/automatic_item_modification_by_age.pl old mode 100755 new mode 100644 index af9f54ceb5c..efc3da6a493 --- a/misc/cronjobs/automatic_item_modification_by_age.pl +++ b/misc/cronjobs/automatic_item_modification_by_age.pl @@ -2,14 +2,14 @@ use Modern::Perl; -use Getopt::Long; -use Pod::Usage; -use JSON; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); +use JSON (); use Koha::Script -cron; use C4::Context; -use C4::Items qw( ToggleNewStatus sub ); -use C4::Log; +use C4::Items (); +use C4::Log qw( cronlogaction ); # Getting options my ( $verbose, $help, $confirm ); diff --git a/misc/cronjobs/automatic_renewals.pl b/misc/cronjobs/automatic_renewals.pl old mode 100755 new mode 100644 index fdf1b2d3d86..02223d13377 --- a/misc/cronjobs/automatic_renewals.pl +++ b/misc/cronjobs/automatic_renewals.pl @@ -75,14 +75,14 @@ chosen 'Digests only' on the advance messages. =cut use Modern::Perl; -use Pod::Usage; -use Getopt::Long; +use Pod::Usage qw( pod2usage ); +use Getopt::Long qw( GetOptions ); use Koha::Script -cron; use C4::Circulation qw( CanBookBeRenewed AddRenewal ); use C4::Context; -use C4::Log; -use C4::Letters qw( GetPreparedLetter EnqueueLetter ); +use C4::Log qw( cronlogaction ); +use C4::Letters (); use Koha::Checkouts; use Koha::Libraries; use Koha::Patrons; diff --git a/misc/cronjobs/batch_anonymise.pl b/misc/cronjobs/batch_anonymise.pl old mode 100755 new mode 100644 index ea63dfa01d0..1b7868256ca --- a/misc/cronjobs/batch_anonymise.pl +++ b/misc/cronjobs/batch_anonymise.pl @@ -19,25 +19,20 @@ use strict; use warnings; -use Carp; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script -cron; use C4::Context; use Koha::Patrons; -use Date::Calc qw( - Today - Add_Delta_Days -); -use Getopt::Long; -use C4::Log; +use Date::Calc qw( Add_Delta_Days Today ); +use Getopt::Long qw( GetOptions ); +use C4::Log qw( cronlogaction ); sub usage { print STDERR <. use Modern::Perl; -use Pod::Usage; -use Getopt::Long; +use Pod::Usage qw( pod2usage ); +use Getopt::Long qw( GetOptions ); use Koha::Script -cron; use C4::Context; use C4::Biblio qw( GetMarcBiblio ); use AnyEvent; -use AnyEvent::HTTP; -use Encode; +use AnyEvent::HTTP qw( http_request ); +use Encode qw( encode_utf8 ); my ( $verbose, $help, $html ) = ( 0, 0, 0 ); my ( $host, $host_intranet ) = ( '', '' ); diff --git a/misc/cronjobs/cleanup_database.pl b/misc/cronjobs/cleanup_database.pl old mode 100755 new mode 100644 index 18971114960..82cda383d64 --- a/misc/cronjobs/cleanup_database.pl +++ b/misc/cronjobs/cleanup_database.pl @@ -31,17 +31,16 @@ 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" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script -cron; use C4::Context; use C4::Search; use C4::Search::History; -use Getopt::Long; -use C4::Log; -use C4::Accounts; +use Getopt::Long qw( GetOptions ); +use C4::Log qw( cronlogaction ); +use C4::Accounts qw( purge_zero_balance_fees ); use Koha::UploadedFiles; use Koha::Old::Biblios; use Koha::Old::Items; diff --git a/misc/cronjobs/cloud-kw.pl b/misc/cronjobs/cloud-kw.pl old mode 100755 new mode 100644 index 3dadf998a73..17448050ebb --- a/misc/cronjobs/cloud-kw.pl +++ b/misc/cronjobs/cloud-kw.pl @@ -21,14 +21,14 @@ use strict; use warnings; use diagnostics; -use Carp; -use YAML::XS; -use Pod::Usage; -use Getopt::Long; +use Carp qw( carp croak ); +use YAML::XS (); +use Pod::Usage qw( pod2usage ); +use Getopt::Long qw( GetOptions ); use Koha::Script -cron; use C4::Context; -use C4::Log; +use C4::Log qw( cronlogaction ); my $verbose = 0; my $help = 0; @@ -97,7 +97,7 @@ package ZebraIndex; use strict; use warnings; use diagnostics; -use Carp; +use Carp qw( carp croak ); sub new { my $self = {}; diff --git a/misc/cronjobs/create_koc_db.pl b/misc/cronjobs/create_koc_db.pl old mode 100755 new mode 100644 index 3d92fe5aa3b..be2938c3092 --- a/misc/cronjobs/create_koc_db.pl +++ b/misc/cronjobs/create_koc_db.pl @@ -91,9 +91,9 @@ use warnings; $|++; -use DBI; -use Getopt::Long; -use Pod::Usage; +use DBI (); +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Script -cron; use C4::Context; diff --git a/misc/cronjobs/delete_items.pl b/misc/cronjobs/delete_items.pl old mode 100755 new mode 100644 index 7422b5c34f1..3f3235f6686 --- a/misc/cronjobs/delete_items.pl +++ b/misc/cronjobs/delete_items.pl @@ -1,13 +1,12 @@ #! /usr/bin/perl -use Getopt::Long; +use Getopt::Long qw( GetOptions ); use Koha::Script -cron; use C4::Context; -use C4::Items qw( sub ); use C4::Circulation; use Modern::Perl; -use Pod::Usage; +use Pod::Usage qw( pod2usage ); my $dbh = C4::Context->dbh(); diff --git a/misc/cronjobs/delete_patrons.pl b/misc/cronjobs/delete_patrons.pl old mode 100755 new mode 100644 index 8d0769b36ca..37a15299755 --- a/misc/cronjobs/delete_patrons.pl +++ b/misc/cronjobs/delete_patrons.pl @@ -2,14 +2,14 @@ use Modern::Perl; -use Pod::Usage; -use Getopt::Long; +use Pod::Usage qw( pod2usage ); +use Getopt::Long qw( GetOptions ); use Koha::Script -cron; use C4::Members qw( GetBorrowersToExpunge ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::Patrons; -use C4::Log; +use C4::Log qw( cronlogaction ); my ( $help, $verbose, $not_borrowed_since, $expired_before, $last_seen, @category_code, $branchcode, $file, $confirm ); diff --git a/misc/cronjobs/delete_records_via_leader.pl b/misc/cronjobs/delete_records_via_leader.pl old mode 100755 new mode 100644 index 22b10d0ed98..c5ceb0efa9b --- a/misc/cronjobs/delete_records_via_leader.pl +++ b/misc/cronjobs/delete_records_via_leader.pl @@ -27,15 +27,13 @@ BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Script -cron; use C4::Biblio qw( DelBiblio ); -use C4::Items; use Koha::Database; use Koha::Biblios; use Koha::Biblio::Metadatas; diff --git a/misc/cronjobs/edi_cron.pl b/misc/cronjobs/edi_cron.pl old mode 100755 new mode 100644 diff --git a/misc/cronjobs/fines.pl b/misc/cronjobs/fines.pl old mode 100755 new mode 100644 index ef90ac3f222..fc0df041c12 --- a/misc/cronjobs/fines.pl +++ b/misc/cronjobs/fines.pl @@ -33,15 +33,15 @@ use 5.010; use Koha::Script -cron; use C4::Context; use C4::Overdues qw( Getoverdues CalcFine UpdateFine ); -use Getopt::Long; -use Carp; -use File::Spec; -use Try::Tiny; +use Getopt::Long qw( GetOptions ); +use Carp qw( carp croak ); +use File::Spec (); +use Try::Tiny qw( catch try ); use Koha::Calendar; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Patrons; -use C4::Log; +use C4::Log qw( cronlogaction ); my $help; my $verbose; diff --git a/misc/cronjobs/gather_print_notices.pl b/misc/cronjobs/gather_print_notices.pl old mode 100755 new mode 100644 index 5da3f0f04ee..4d99b84ebbc --- a/misc/cronjobs/gather_print_notices.pl +++ b/misc/cronjobs/gather_print_notices.pl @@ -5,23 +5,21 @@ use Modern::Perl; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } -use CGI qw( utf8 ); # NOT a CGI script, this is just to keep C4::Templates::gettemplate happy +use CGI (); # NOT a CGI script, this is just to keep C4::Templates::gettemplate happy use Koha::Script -cron; use C4::Context; -use C4::Debug; use C4::Letters qw( GetPrintMessages _set_message_status ); use C4::Templates; -use File::Spec; -use Pod::Usage; -use Getopt::Long; -use C4::Log; +use File::Spec (); +use Pod::Usage qw( pod2usage ); +use Getopt::Long qw( GetOptions ); +use C4::Log qw( cronlogaction ); -use Koha::DateUtils; -use Koha::Util::OpenDocument; +use Koha::DateUtils qw( dt_from_string output_pref ); +use Koha::Util::OpenDocument qw( generate_ods ); use MIME::Lite; my ( diff --git a/misc/cronjobs/holds/auto_unsuspend_holds.pl b/misc/cronjobs/holds/auto_unsuspend_holds.pl old mode 100755 new mode 100644 index eb4fd874a7f..15cc2a4f233 --- a/misc/cronjobs/holds/auto_unsuspend_holds.pl +++ b/misc/cronjobs/holds/auto_unsuspend_holds.pl @@ -23,15 +23,14 @@ use warnings; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } # cancel all expired hold requests use Koha::Script -cron; use C4::Reserves; -use C4::Log; +use C4::Log qw( cronlogaction ); cronlogaction(); diff --git a/misc/cronjobs/holds/build_holds_queue.pl b/misc/cronjobs/holds/build_holds_queue.pl old mode 100755 new mode 100644 index ab138f91833..1bb3f489a49 --- a/misc/cronjobs/holds/build_holds_queue.pl +++ b/misc/cronjobs/holds/build_holds_queue.pl @@ -11,13 +11,12 @@ use warnings; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script -cron; use C4::HoldsQueue qw(CreateQueue); -use C4::Log; +use C4::Log qw( cronlogaction ); cronlogaction(); diff --git a/misc/cronjobs/holds/cancel_expired_holds.pl b/misc/cronjobs/holds/cancel_expired_holds.pl old mode 100755 new mode 100644 index 4932bbf3469..4cf941dfe9a --- a/misc/cronjobs/holds/cancel_expired_holds.pl +++ b/misc/cronjobs/holds/cancel_expired_holds.pl @@ -39,19 +39,18 @@ This script calls C4::Reserves::CancelExpiredReserves which will find and cancel =cut use Modern::Perl; -use Getopt::Long; -use Pod::Usage; +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" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script -cron; use C4::Reserves; -use C4::Log; +use C4::Log qw( cronlogaction ); =head1 OPTIONS diff --git a/misc/cronjobs/holds/cancel_unfilled_holds.pl b/misc/cronjobs/holds/cancel_unfilled_holds.pl old mode 100755 new mode 100644 index ba6a40098a0..2e4b4f54566 --- a/misc/cronjobs/holds/cancel_unfilled_holds.pl +++ b/misc/cronjobs/holds/cancel_unfilled_holds.pl @@ -21,19 +21,17 @@ use Modern::Perl; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Script -cron; use C4::Reserves; -use C4::Log; +use C4::Log qw( cronlogaction ); use Koha::Holds; use Koha::Calendar; -use Koha::DateUtils; use Koha::Libraries; cronlogaction(); diff --git a/misc/cronjobs/holds/holds_reminder.pl b/misc/cronjobs/holds/holds_reminder.pl old mode 100755 new mode 100644 index 49bccfdcde6..76dd8b7fa07 --- a/misc/cronjobs/holds/holds_reminder.pl +++ b/misc/cronjobs/holds/holds_reminder.pl @@ -21,20 +21,18 @@ BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } -use Getopt::Long; -use Pod::Usage; -use Text::CSV_XS; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use DateTime; use DateTime::Duration; use C4::Context; -use C4::Letters; -use C4::Log; -use Koha::DateUtils; +use C4::Letters (); +use C4::Log qw( cronlogaction ); +use Koha::DateUtils qw( dt_from_string ); use Koha::Calendar; use Koha::Libraries; use Koha::Script -cron; diff --git a/misc/cronjobs/import_webservice_batch.pl b/misc/cronjobs/import_webservice_batch.pl old mode 100755 new mode 100644 index 8c9a17cadac..e775532ff3f --- a/misc/cronjobs/import_webservice_batch.pl +++ b/misc/cronjobs/import_webservice_batch.pl @@ -25,12 +25,10 @@ BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } -use Getopt::Long; -use Pod::Usage; +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 old mode 100755 new mode 100644 index 5ce1cfa1b1e..60a1ec2f74e --- a/misc/cronjobs/longoverdue.pl +++ b/misc/cronjobs/longoverdue.pl @@ -30,17 +30,15 @@ use warnings; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use C4::Circulation qw( LostItem MarkIssueReturned ); use C4::Context; -use C4::Items qw( sub ); -use C4::Log; +use C4::Log qw( cronlogaction ); use Koha::ItemTypes; use Koha::Patron::Categories; use Koha::Patrons; diff --git a/misc/cronjobs/membership_expiry.pl b/misc/cronjobs/membership_expiry.pl old mode 100755 new mode 100644 index d7d15d0c777..a753beb458c --- a/misc/cronjobs/membership_expiry.pl +++ b/misc/cronjobs/membership_expiry.pl @@ -116,20 +116,18 @@ any field from the branches table =cut use Modern::Perl; -use Getopt::Long; -use Pod::Usage; -use Data::Dumper; +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" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script -cron; use C4::Context; -use C4::Letters qw( GetPreparedLetter EnqueueLetter ); -use C4::Log; +use C4::Letters (); +use C4::Log qw( cronlogaction ); use Koha::Patrons; diff --git a/misc/cronjobs/merge_authorities.pl b/misc/cronjobs/merge_authorities.pl old mode 100755 new mode 100644 index 727d7d5f8c8..1645cfdda43 --- a/misc/cronjobs/merge_authorities.pl +++ b/misc/cronjobs/merge_authorities.pl @@ -1,9 +1,9 @@ #!/usr/bin/perl use Modern::Perl; -use Getopt::Long; -use Pod::Usage; -use Time::HiRes qw(gettimeofday); +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); +use Time::HiRes qw( gettimeofday ); use Koha::Script -cron; use C4::AuthoritiesMarc; diff --git a/misc/cronjobs/notice_unprocessed_suggestions.pl b/misc/cronjobs/notice_unprocessed_suggestions.pl old mode 100755 new mode 100644 index 055315c9dd7..2516828ae2d --- a/misc/cronjobs/notice_unprocessed_suggestions.pl +++ b/misc/cronjobs/notice_unprocessed_suggestions.pl @@ -2,8 +2,8 @@ use Modern::Perl; -use Pod::Usage; -use Getopt::Long; +use Pod::Usage qw( pod2usage ); +use Getopt::Long qw( GetOptions ); use Koha::Script -cron; use C4::Budgets qw( GetBudget ); diff --git a/misc/cronjobs/overdue_notices.pl b/misc/cronjobs/overdue_notices.pl old mode 100755 new mode 100644 index 76d7cd5a5e0..00ad1b88184 --- a/misc/cronjobs/overdue_notices.pl +++ b/misc/cronjobs/overdue_notices.pl @@ -24,23 +24,22 @@ BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } -use Getopt::Long; -use Pod::Usage; -use Text::CSV_XS; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); +use Text::CSV_XS (); use DateTime; use DateTime::Duration; use Koha::Script -cron; use C4::Context; -use C4::Letters qw( getletter get_item_content EnqueueLetter ); -use C4::Overdues qw( GetBranchcodesWithOverdueRules GetOverdueMessageTransportTypes parse_overdues_letter ); -use C4::Log; -use Koha::Patron::Debarments qw(AddUniqueDebarment); -use Koha::DateUtils; +use C4::Letters (); +use C4::Overdues qw( GetOverdueMessageTransportTypes parse_overdues_letter ); +use C4::Log qw( cronlogaction ); +use Koha::Patron::Debarments qw( AddUniqueDebarment ); +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Calendar; use Koha::Libraries; use Koha::Acquisition::Currencies; diff --git a/misc/cronjobs/patron_emailer.pl b/misc/cronjobs/patron_emailer.pl old mode 100755 new mode 100644 index 6ee1ff98e5c..d4d39bd6516 --- a/misc/cronjobs/patron_emailer.pl +++ b/misc/cronjobs/patron_emailer.pl @@ -21,15 +21,14 @@ use Modern::Perl; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script -cron; -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); -use C4::Log; +use C4::Log qw( cronlogaction ); use C4::Reports::Guided qw( EmailReport ); cronlogaction(); diff --git a/misc/cronjobs/plugins_nightly.pl b/misc/cronjobs/plugins_nightly.pl old mode 100755 new mode 100644 index f748637e1ea..a90423e749e --- a/misc/cronjobs/plugins_nightly.pl +++ b/misc/cronjobs/plugins_nightly.pl @@ -2,10 +2,10 @@ use Modern::Perl; -use Try::Tiny; +use Try::Tiny qw( catch try ); use C4::Context; -use C4::Log; +use C4::Log qw( cronlogaction ); use Koha::Logger; use Koha::Plugins; use Koha::Script -cron; diff --git a/misc/cronjobs/process_message_queue.pl b/misc/cronjobs/process_message_queue.pl old mode 100755 new mode 100644 index cc9a85ae1f8..bcdc7d274b0 --- a/misc/cronjobs/process_message_queue.pl +++ b/misc/cronjobs/process_message_queue.pl @@ -22,15 +22,14 @@ use warnings; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script -cron; use C4::Letters qw( SendQueuedMessages ); -use C4::Log; -use Getopt::Long; -use Try::Tiny; +use C4::Log qw( cronlogaction ); +use Getopt::Long qw( GetOptions ); +use Try::Tiny qw( catch try ); my $username = undef; my $password = undef; diff --git a/misc/cronjobs/purge_suggestions.pl b/misc/cronjobs/purge_suggestions.pl old mode 100755 new mode 100644 index 9fdc26d566b..3d6649bb072 --- a/misc/cronjobs/purge_suggestions.pl +++ b/misc/cronjobs/purge_suggestions.pl @@ -22,16 +22,14 @@ use Modern::Perl; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); use Koha::Script -cron; use C4::Suggestions; -use C4::Log; +use C4::Log qw( cronlogaction ); use C4::Context; my ( $help, $days, $confirm ); diff --git a/misc/cronjobs/reconcile_balances.pl b/misc/cronjobs/reconcile_balances.pl old mode 100755 new mode 100644 index 0202de94500..c73a8a04e11 --- a/misc/cronjobs/reconcile_balances.pl +++ b/misc/cronjobs/reconcile_balances.pl @@ -51,19 +51,18 @@ Makes the process print information about the taken actions. use Modern::Perl; -use Getopt::Long; -use Pod::Usage; -use Try::Tiny; +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" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script -cron; -use C4::Log; +use C4::Log qw( cronlogaction ); use Koha::Account::Lines; use Koha::Patrons; diff --git a/misc/cronjobs/remove_temporary_edifiles.pl b/misc/cronjobs/remove_temporary_edifiles.pl old mode 100755 new mode 100644 diff --git a/misc/cronjobs/rss/rss.pl b/misc/cronjobs/rss/rss.pl old mode 100755 new mode 100644 index e703d07a799..d107411044f --- a/misc/cronjobs/rss/rss.pl +++ b/misc/cronjobs/rss/rss.pl @@ -31,8 +31,7 @@ use Template; use Koha::Script -cron; use C4::Context; -use Time::Local; -use POSIX; +use POSIX qw( close localtime open strftime ); my $dbh = C4::Context->dbh; my $file = $ARGV[0]; diff --git a/misc/cronjobs/runreport.pl b/misc/cronjobs/runreport.pl old mode 100755 new mode 100644 index c43616f7fb0..af8d00ef590 --- a/misc/cronjobs/runreport.pl +++ b/misc/cronjobs/runreport.pl @@ -24,25 +24,24 @@ use Koha::Script -cron; use C4::Reports::Guided qw( store_results execute_query ); use Koha::Reports; use C4::Context; -use C4::Log; +use C4::Log qw( cronlogaction ); use Koha::Email; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::SMTP::Servers; use Getopt::Long qw(:config auto_help auto_version); -use Pod::Usage; +use Pod::Usage qw( pod2usage ); use Text::CSV::Encoded; use CGI qw ( -utf8 ); -use Carp; -use Encode; +use Carp qw( carp ); +use Encode qw( decode ); use JSON qw( to_json ); -use Try::Tiny; +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" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } =head1 NAME diff --git a/misc/cronjobs/serialsUpdate.pl b/misc/cronjobs/serialsUpdate.pl old mode 100755 new mode 100644 index e5f4ac34438..42b0558a6f0 --- a/misc/cronjobs/serialsUpdate.pl +++ b/misc/cronjobs/serialsUpdate.pl @@ -24,21 +24,19 @@ BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script -cron; use C4::Context; -use C4::Debug; use C4::Serials qw( GetSubscription GetNextDate ModSerialStatus ); -use C4::Log; -use Koha::DateUtils; +use C4::Log qw( cronlogaction ); +use Koha::DateUtils qw( dt_from_string output_pref ); use C4::Serials qw( GetSubscription GetNextDate ModSerialStatus ); -use Date::Calc qw/Date_to_Days check_date/; -use Getopt::Long; -use Pod::Usage; +use Date::Calc qw( check_date Date_to_Days ); +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); =head1 NAME diff --git a/misc/cronjobs/share_usage_with_koha_community.pl b/misc/cronjobs/share_usage_with_koha_community.pl old mode 100755 new mode 100644 index a427ca037b8..fa6d59850f4 --- a/misc/cronjobs/share_usage_with_koha_community.pl +++ b/misc/cronjobs/share_usage_with_koha_community.pl @@ -2,14 +2,14 @@ use Modern::Perl; -use Pod::Usage; -use Getopt::Long; +use Pod::Usage qw( pod2usage ); +use Getopt::Long qw( GetOptions ); use Koha::Script -cron; use C4::Context; use C4::UsageStats; -use C4::Log; -use POSIX qw(strftime); +use C4::Log qw( cronlogaction ); +use POSIX qw( strftime ); my ( $help, $verbose, $force, $quiet ); GetOptions( diff --git a/misc/cronjobs/sitemap.pl b/misc/cronjobs/sitemap.pl old mode 100755 new mode 100644 index fb738e08232..113b3f47e16 --- a/misc/cronjobs/sitemap.pl +++ b/misc/cronjobs/sitemap.pl @@ -21,12 +21,11 @@ package Main; use Modern::Perl; use utf8; -use Pod::Usage; -use Getopt::Long; +use Pod::Usage qw( pod2usage ); +use Getopt::Long qw( GetOptions ); use Koha::Script -cron; -use C4::Biblio; -use Koha::Sitemapper; +use Koha::Sitemapper (); my ($verbose, $help, $url, $dir, $short) = (0, 0, '', '.', 1); diff --git a/misc/cronjobs/social_data/get_report_social_data.pl b/misc/cronjobs/social_data/get_report_social_data.pl old mode 100755 new mode 100644 diff --git a/misc/cronjobs/social_data/update_social_data.pl b/misc/cronjobs/social_data/update_social_data.pl old mode 100755 new mode 100644 diff --git a/misc/cronjobs/staticfines.pl b/misc/cronjobs/staticfines.pl old mode 100755 new mode 100644 index 4a4673ab3fa..b3806f21538 --- a/misc/cronjobs/staticfines.pl +++ b/misc/cronjobs/staticfines.pl @@ -31,23 +31,21 @@ BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/kohalib.pl" }; + eval { require "$FindBin::Bin/kohalib.pl" }; } -use Date::Calc qw/Date_to_Days/; +use Date::Calc qw( Date_to_Days ); use Koha::Script -cron; use C4::Context; use C4::Circulation; -use C4::Overdues qw( checkoverdues Getoverdues CalcFine GetFine ); +use C4::Overdues qw( CalcFine checkoverdues GetFine Getoverdues ); use C4::Calendar qw(); # don't need any exports from Calendar -use C4::Biblio; -use C4::Debug; # supplying $debug and $cgi_debug -use C4::Log; -use Getopt::Long; -use List::MoreUtils qw/none/; -use Koha::DateUtils; +use C4::Debug qw( $debug ); # supplying $debug and $cgi_debug +use C4::Log qw( cronlogaction ); +use Getopt::Long qw( GetOptions ); +use List::MoreUtils qw( none ); +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Patrons; my $help = 0; diff --git a/misc/cronjobs/stockrotation.pl b/misc/cronjobs/stockrotation.pl old mode 100755 new mode 100644 diff --git a/misc/cronjobs/thirdparty/TalkingTech_itiva_inbound.pl b/misc/cronjobs/thirdparty/TalkingTech_itiva_inbound.pl old mode 100755 new mode 100644 index f00d9d6a342..05779c7fbb5 --- a/misc/cronjobs/thirdparty/TalkingTech_itiva_inbound.pl +++ b/misc/cronjobs/thirdparty/TalkingTech_itiva_inbound.pl @@ -24,12 +24,11 @@ BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Script -cron; use C4::Context; diff --git a/misc/cronjobs/thirdparty/TalkingTech_itiva_outbound.pl b/misc/cronjobs/thirdparty/TalkingTech_itiva_outbound.pl old mode 100755 new mode 100644 index 83b8a1a4421..bfbf67b3e93 --- a/misc/cronjobs/thirdparty/TalkingTech_itiva_outbound.pl +++ b/misc/cronjobs/thirdparty/TalkingTech_itiva_outbound.pl @@ -24,20 +24,18 @@ BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Script -cron; use C4::Context; -use C4::Items; -use C4::Letters; +use C4::Letters (); use C4::Overdues; use Koha::Calendar; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Patrons; use Koha::Libraries; diff --git a/misc/cronjobs/update_patrons_category.pl b/misc/cronjobs/update_patrons_category.pl old mode 100755 new mode 100644 index 86541a818d7..19bc276193a --- a/misc/cronjobs/update_patrons_category.pl +++ b/misc/cronjobs/update_patrons_category.pl @@ -20,17 +20,16 @@ use Modern::Perl; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use C4::Context; -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Logger; use Koha::Patrons; use Koha::Patron::Categories; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::Script -cron; =head1 NAME diff --git a/misc/cronjobs/update_totalissues.pl b/misc/cronjobs/update_totalissues.pl old mode 100755 new mode 100644 index fcd8f871d43..d644be3871a --- a/misc/cronjobs/update_totalissues.pl +++ b/misc/cronjobs/update_totalissues.pl @@ -24,22 +24,21 @@ BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Script -cron; -use Koha::DateUtils qw/ dt_from_string /; +use Koha::DateUtils qw( dt_from_string ); use C4::Context; use C4::Biblio qw( UpdateTotalIssues ); -use C4::Log; +use C4::Log qw( cronlogaction ); use DateTime; use DateTime::Format::MySQL; -use Time::HiRes qw/time/; -use POSIX qw/strftime ceil/; +use Time::HiRes qw( time ); +use POSIX qw( ceil strftime ); sub usage { pod2usage( -verbose => 2 ); diff --git a/misc/cronjobs/writeoff_debts.pl b/misc/cronjobs/writeoff_debts.pl old mode 100755 new mode 100644 index ae2ee9c0de2..9b207a59e54 --- a/misc/cronjobs/writeoff_debts.pl +++ b/misc/cronjobs/writeoff_debts.pl @@ -3,11 +3,11 @@ use Modern::Perl; use feature 'say'; -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Account::Lines; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::Script -cron; diff --git a/misc/devel/add_missing_filters.pl b/misc/devel/add_missing_filters.pl old mode 100755 new mode 100644 index cc1b877e1e9..51e7c1da5a8 --- a/misc/devel/add_missing_filters.pl +++ b/misc/devel/add_missing_filters.pl @@ -2,9 +2,9 @@ use Modern::Perl; -use File::Slurp; -use Pod::Usage; -use Getopt::Long; +use File::Slurp qw( read_file write_file ); +use Pod::Usage qw( pod2usage ); +use Getopt::Long qw( GetOptions ); use t::lib::QA::TemplateFilters; diff --git a/misc/devel/coverage.pl b/misc/devel/coverage.pl old mode 100755 new mode 100644 index 3dabae72bc9..a4d09344cc4 --- a/misc/devel/coverage.pl +++ b/misc/devel/coverage.pl @@ -48,9 +48,9 @@ prints this help text use Modern::Perl; use C4::Context; -use Cwd; -use Getopt::Long; -use Pod::Usage; +use Cwd qw( getcwd ); +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); my $help; diff --git a/misc/devel/create_superlibrarian.pl b/misc/devel/create_superlibrarian.pl old mode 100755 new mode 100644 index 28c67b66d82..c0ab6fe6c6b --- a/misc/devel/create_superlibrarian.pl +++ b/misc/devel/create_superlibrarian.pl @@ -18,8 +18,8 @@ # along with Koha; if not, see . use Modern::Perl; -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Script; use Koha::Patrons; diff --git a/misc/devel/get_prepared_letter.pl b/misc/devel/get_prepared_letter.pl old mode 100755 new mode 100644 index 58dbef2db6b..5ef852cb255 --- a/misc/devel/get_prepared_letter.pl +++ b/misc/devel/get_prepared_letter.pl @@ -69,9 +69,9 @@ documentation of GetPreparedLetter for more informations. use Modern::Perl; -use Getopt::Long; -use JSON; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use JSON qw( decode_json ); +use Pod::Usage qw( pod2usage ); use C4::Letters qw( GetPreparedLetter ); diff --git a/misc/devel/install_plugins.pl b/misc/devel/install_plugins.pl old mode 100755 new mode 100644 index 0177d733b46..8e2cee9ad98 --- a/misc/devel/install_plugins.pl +++ b/misc/devel/install_plugins.pl @@ -18,8 +18,8 @@ # along with Koha; if not, see . use Modern::Perl; -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Script; diff --git a/misc/devel/update_dbix_class_files.pl b/misc/devel/update_dbix_class_files.pl old mode 100755 new mode 100644 index 7e00b8f447b..747c000708b --- a/misc/devel/update_dbix_class_files.pl +++ b/misc/devel/update_dbix_class_files.pl @@ -21,8 +21,8 @@ use Modern::Perl; use DBIx::Class::Schema::Loader qw/ make_schema_at /; -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); my %db_defaults = ( driver => 'mysql', diff --git a/misc/export_borrowers.pl b/misc/export_borrowers.pl old mode 100755 new mode 100644 diff --git a/misc/export_records.pl b/misc/export_records.pl old mode 100755 new mode 100644 index 2a05e794dfd..32658cb8c8c --- a/misc/export_records.pl +++ b/misc/export_records.pl @@ -18,9 +18,9 @@ use Modern::Perl; use MARC::File::XML; -use List::MoreUtils qw(uniq); -use Getopt::Long; -use Pod::Usage; +use List::MoreUtils qw( uniq ); +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Script; use C4::Auth; diff --git a/misc/exportauth.pl b/misc/exportauth.pl old mode 100755 new mode 100644 index c036b17063a..2a3363b1f81 --- a/misc/exportauth.pl +++ b/misc/exportauth.pl @@ -8,13 +8,11 @@ use strict; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/kohalib.pl" }; + eval { require "$FindBin::Bin/kohalib.pl" }; } use Koha::Script; use C4::Context; -use C4::Biblio; use C4::Auth; my $outfile = $ARGV[0]; open(my $fh, '>', $outfile) or die $!; diff --git a/misc/import_patrons.pl b/misc/import_patrons.pl old mode 100755 new mode 100644 index b3bbb66e87e..80eecf059d3 --- a/misc/import_patrons.pl +++ b/misc/import_patrons.pl @@ -19,11 +19,11 @@ use Modern::Perl; -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Script; -use Koha::Patrons::Import; +use Koha::Patrons::Import (); my $Import = Koha::Patrons::Import->new(); my $csv_file; diff --git a/misc/kohalib.pl b/misc/kohalib.pl old mode 100755 new mode 100644 diff --git a/misc/link_bibs_to_authorities.pl b/misc/link_bibs_to_authorities.pl old mode 100755 new mode 100644 index dfe83320734..c761b590604 --- a/misc/link_bibs_to_authorities.pl +++ b/misc/link_bibs_to_authorities.pl @@ -7,19 +7,22 @@ BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/kohalib.pl" }; + eval { require "$FindBin::Bin/kohalib.pl" }; } use Koha::Script; use C4::Context; -use C4::Biblio qw( GetMarcBiblio GetFrameworkCode LinkBibHeadingsToAuthorities ModBiblio ); -use Getopt::Long; -use Pod::Usage; -use Data::Dumper; -use Time::HiRes qw/time/; -use POSIX qw/strftime ceil/; -use Module::Load::Conditional qw(can_load); +use C4::Biblio qw( + GetFrameworkCode + GetMarcBiblio + LinkBibHeadingsToAuthorities + ModBiblio +); +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); +use Time::HiRes qw( time ); +use POSIX qw( ceil strftime ); +use Module::Load::Conditional qw( can_load ); sub usage { pod2usage( -verbose => 2 ); diff --git a/misc/load_testing/benchmark_circulation.pl b/misc/load_testing/benchmark_circulation.pl old mode 100755 new mode 100644 index 36ab41881fd..bd04313d498 --- a/misc/load_testing/benchmark_circulation.pl +++ b/misc/load_testing/benchmark_circulation.pl @@ -7,13 +7,11 @@ use warnings; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/kohalib.pl" }; + eval { require "$FindBin::Bin/kohalib.pl" }; } use HTTPD::Bench::ApacheBench; -use LWP::UserAgent; -use Data::Dumper; +use LWP::UserAgent (); use HTTP::Cookies; use C4::Context; diff --git a/misc/load_testing/benchmark_staff.pl b/misc/load_testing/benchmark_staff.pl old mode 100755 new mode 100644 index 9c0a92fc54e..669f0e8b702 --- a/misc/load_testing/benchmark_staff.pl +++ b/misc/load_testing/benchmark_staff.pl @@ -7,18 +7,16 @@ use warnings; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/kohalib.pl" }; + eval { require "$FindBin::Bin/kohalib.pl" }; } -use Getopt::Long; +use Getopt::Long qw( GetOptions ); use HTTPD::Bench::ApacheBench; -use LWP::UserAgent; -use Data::Dumper; +use LWP::UserAgent (); use HTTP::Cookies; use C4::Context; -use C4::Debug; -use URI::Escape; +use C4::Debug qw( $debug ); +use URI::Escape qw( uri_escape_utf8 ); use Koha::Patrons; my ($help, $steps, $baseurl, $max_tries, $user, $password,$short_print); diff --git a/misc/load_testing/benchmark_webservices.pl b/misc/load_testing/benchmark_webservices.pl old mode 100755 new mode 100644 index e79067d0ea7..50913574d58 --- a/misc/load_testing/benchmark_webservices.pl +++ b/misc/load_testing/benchmark_webservices.pl @@ -15,9 +15,8 @@ use warnings; # records/xml/xml-recs.xml = file of 1 marcxml record to post # # Requires LWP::UserAgent, File::Slurp. -use LWP::UserAgent; -use File::Slurp qw(slurp); -use Carp; +use LWP::UserAgent (); +use File::Slurp qw( slurp ); my $ua = LWP::UserAgent->new(); $ua->cookie_jar({ file =>"cookies.txt" }); my $baseurl = shift; diff --git a/misc/load_yaml.pl b/misc/load_yaml.pl old mode 100755 new mode 100644 index 362a2512505..f58214fc84e --- a/misc/load_yaml.pl +++ b/misc/load_yaml.pl @@ -22,7 +22,7 @@ use Modern::Perl; use Koha::Script; use Getopt::Long qw(:config no_ignore_case); use C4::Context; -use C4::Installer; +use C4::Installer (); sub print_usage { ( my $basename = $0 ) =~ s|.*/||; diff --git a/misc/maintenance/UNIMARC_fix_collectiontitle.pl b/misc/maintenance/UNIMARC_fix_collectiontitle.pl old mode 100755 new mode 100644 index 4a97c18e562..15e3ca06378 --- a/misc/maintenance/UNIMARC_fix_collectiontitle.pl +++ b/misc/maintenance/UNIMARC_fix_collectiontitle.pl @@ -8,12 +8,10 @@ use strict; use warnings; BEGIN { - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script; -use C4::Biblio; 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 old mode 100755 new mode 100644 index 5c3a975de2d..eafaa76b57c --- a/misc/maintenance/UNIMARC_sync_date_created_with_marc_biblio.pl +++ b/misc/maintenance/UNIMARC_sync_date_created_with_marc_biblio.pl @@ -8,13 +8,12 @@ use strict; use warnings; BEGIN { - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script; use C4::Biblio qw( GetMarcBiblio ModBiblio ); -use Getopt::Long; +use Getopt::Long qw( GetOptions ); sub _read_marc_code { my $input = shift; diff --git a/misc/maintenance/auth_show_hidden_data.pl b/misc/maintenance/auth_show_hidden_data.pl old mode 100755 new mode 100644 index 91006d17617..fdab6357686 --- a/misc/maintenance/auth_show_hidden_data.pl +++ b/misc/maintenance/auth_show_hidden_data.pl @@ -22,8 +22,8 @@ # which hidden fields in the framework still contain data. use Modern::Perl; -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Script; use Koha::Authorities; diff --git a/misc/maintenance/borrowers-force-messaging-defaults.pl b/misc/maintenance/borrowers-force-messaging-defaults.pl old mode 100755 new mode 100644 index 0e30596879c..0bbccc59372 --- a/misc/maintenance/borrowers-force-messaging-defaults.pl +++ b/misc/maintenance/borrowers-force-messaging-defaults.pl @@ -22,15 +22,14 @@ use warnings; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script; use C4::Context; use C4::Members::Messaging; -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); sub usage { diff --git a/misc/maintenance/check_syspref_cache.pl b/misc/maintenance/check_syspref_cache.pl old mode 100755 new mode 100644 index a25b977bda5..9328988baf1 --- a/misc/maintenance/check_syspref_cache.pl +++ b/misc/maintenance/check_syspref_cache.pl @@ -16,8 +16,8 @@ # along with Koha; if not, see . use Modern::Perl; -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Encode qw( encode_utf8 ); use Koha::Script; diff --git a/misc/maintenance/cmp_sysprefs.pl b/misc/maintenance/cmp_sysprefs.pl old mode 100755 new mode 100644 index 90b21a7c022..1a7afdf63a9 --- a/misc/maintenance/cmp_sysprefs.pl +++ b/misc/maintenance/cmp_sysprefs.pl @@ -27,8 +27,8 @@ use Modern::Perl; use open OUT => ':encoding(UTF-8)', ':std'; -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Script; use C4::Context; diff --git a/misc/maintenance/compare_es_to_db.pl b/misc/maintenance/compare_es_to_db.pl old mode 100755 new mode 100644 diff --git a/misc/maintenance/fix_accountlines_date.pl b/misc/maintenance/fix_accountlines_date.pl old mode 100755 new mode 100644 index 0c7a92e1788..8dc0574d7ab --- a/misc/maintenance/fix_accountlines_date.pl +++ b/misc/maintenance/fix_accountlines_date.pl @@ -22,15 +22,13 @@ use warnings; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script; use C4::Context; -use Getopt::Long; -use Pod::Usage; -use Koha::DateUtils; +use Getopt::Long qw( GetOptions ); +use Koha::DateUtils qw( dt_from_string output_pref ); =head1 NAME diff --git a/misc/maintenance/fix_accountlines_rmdupfines_bug8253.pl b/misc/maintenance/fix_accountlines_rmdupfines_bug8253.pl old mode 100755 new mode 100644 index 4a72e1a0f28..57ae4753e14 --- a/misc/maintenance/fix_accountlines_rmdupfines_bug8253.pl +++ b/misc/maintenance/fix_accountlines_rmdupfines_bug8253.pl @@ -23,16 +23,14 @@ use warnings; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script; use C4::Context; -use C4::Installer; -use Getopt::Long; -use Data::Dumper; +use Getopt::Long qw( GetOptions ); +use Data::Dumper (); sub print_usage { print <<_USAGE_ diff --git a/misc/maintenance/fix_mysql_constraints.pl b/misc/maintenance/fix_mysql_constraints.pl old mode 100755 new mode 100644 index e2920e8fd40..8f992c0e5f3 --- a/misc/maintenance/fix_mysql_constraints.pl +++ b/misc/maintenance/fix_mysql_constraints.pl @@ -21,14 +21,13 @@ use Modern::Perl; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - my $lib = "$FindBin::Bin/../kohalib.pl"; + my $lib = "$FindBin::Bin/../kohalib.pl"; eval { require $lib }; } -use Getopt::Long; -use Pod::Usage; -use Try::Tiny; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); +use Try::Tiny qw( catch try ); use Koha::Script; use C4::Context; diff --git a/misc/maintenance/fix_tags_weight.pl b/misc/maintenance/fix_tags_weight.pl old mode 100755 new mode 100644 index 446fca85890..95dc973f28c --- a/misc/maintenance/fix_tags_weight.pl +++ b/misc/maintenance/fix_tags_weight.pl @@ -20,7 +20,7 @@ use Modern::Perl; use C4::Context; -use C4::Tags qw( add_tag_approval add_tag ); +use C4::Tags (); use Koha::Script; use Koha::Database; @@ -28,8 +28,8 @@ use Koha::Tags; use Koha::Tags::Approvals; use Koha::Tags::Indexes; -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); =head1 NAME diff --git a/misc/maintenance/generate_MARC21Languages.pl b/misc/maintenance/generate_MARC21Languages.pl old mode 100755 new mode 100644 index be27b6e6354..8a70a4f4488 --- a/misc/maintenance/generate_MARC21Languages.pl +++ b/misc/maintenance/generate_MARC21Languages.pl @@ -19,10 +19,10 @@ # use Modern::Perl; -use XML::Simple; -use Pod::Usage; -use Getopt::Long; -use Carp; +use XML::Simple qw( XMLin ); +use Pod::Usage qw( pod2usage ); +use Getopt::Long qw( GetOptions ); +use Carp qw( croak ); use open ':std', ':encoding(UTF-8)'; diff --git a/misc/maintenance/process_record_through_filter.pl b/misc/maintenance/process_record_through_filter.pl old mode 100755 new mode 100644 index 6acfc8eb515..8259e315660 --- a/misc/maintenance/process_record_through_filter.pl +++ b/misc/maintenance/process_record_through_filter.pl @@ -9,7 +9,6 @@ use warnings; use Koha::Script; use Koha::RecordProcessor; -use Data::Dumper; use C4::Biblio qw( GetMarcBiblio ); my $record = GetMarcBiblio({ biblionumber => $ARGV[0] }); diff --git a/misc/maintenance/remove_items_from_biblioitems.pl b/misc/maintenance/remove_items_from_biblioitems.pl old mode 100755 new mode 100644 index 6524807eedb..029e1e9ef06 --- a/misc/maintenance/remove_items_from_biblioitems.pl +++ b/misc/maintenance/remove_items_from_biblioitems.pl @@ -24,8 +24,8 @@ $|=1; use Koha::Script; use C4::Context; -use C4::Biblio qw( GetMarcBiblio ModBiblio GetFrameworkCode ); -use Getopt::Long; +use C4::Biblio qw( GetFrameworkCode GetMarcBiblio ModBiblio ); +use Getopt::Long qw( GetOptions ); my ($wherestring, $run, $silent, $want_help); my $result = GetOptions( diff --git a/misc/maintenance/sanitize_records.pl b/misc/maintenance/sanitize_records.pl old mode 100755 new mode 100644 index bd9202eca7e..9ddbdf9a288 --- a/misc/maintenance/sanitize_records.pl +++ b/misc/maintenance/sanitize_records.pl @@ -20,12 +20,11 @@ use Modern::Perl; use Koha::Script; -use C4::Charset qw( SanitizeRecord ); +use C4::Charset (); use C4::Context; -use DBI; -use C4::Biblio qw( GetMarcBiblio GetFrameworkCode ModBiblio ); -use Getopt::Long; -use Pod::Usage; +use C4::Biblio (); +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); my ( $help, $verbose, $confirm, $biblionumbers, $reindex, $filename, $auto_search, $fix_ampersand ); diff --git a/misc/maintenance/search_for_data_inconsistencies.pl b/misc/maintenance/search_for_data_inconsistencies.pl old mode 100755 new mode 100644 index a23e7abdc70..31bb435a8c1 --- a/misc/maintenance/search_for_data_inconsistencies.pl +++ b/misc/maintenance/search_for_data_inconsistencies.pl @@ -25,7 +25,7 @@ use Koha::BiblioFrameworks; use Koha::Biblioitems; use Koha::Items; use Koha::ItemTypes; -use C4::Biblio qw( GetMarcFromKohaField ); +use C4::Biblio (); { my $items = Koha::Items->search({ -or => { homebranch => undef, holdingbranch => undef }}); diff --git a/misc/maintenance/touch_all_biblios.pl b/misc/maintenance/touch_all_biblios.pl old mode 100755 new mode 100644 index a211630eec7..4f6d5d6488b --- a/misc/maintenance/touch_all_biblios.pl +++ b/misc/maintenance/touch_all_biblios.pl @@ -22,17 +22,16 @@ use warnings; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } # possible modules to use -use Getopt::Long; +use Getopt::Long qw( GetOptions ); use Koha::Script; use C4::Context; use C4::Biblio qw( GetMarcBiblio ModBiblio ); -use Pod::Usage; +use Pod::Usage qw( pod2usage ); sub usage { diff --git a/misc/maintenance/touch_all_items.pl b/misc/maintenance/touch_all_items.pl old mode 100755 new mode 100644 index ba4a497c93d..6bdce034da7 --- a/misc/maintenance/touch_all_items.pl +++ b/misc/maintenance/touch_all_items.pl @@ -22,18 +22,16 @@ use warnings; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } # possible modules to use -use Getopt::Long; +use Getopt::Long qw( GetOptions ); use Koha::Script; use C4::Context; -use C4::Items qw( sub ); use Koha::Items; -use Pod::Usage; +use Pod::Usage qw( pod2usage ); sub usage { diff --git a/misc/maintenance/update_authorities.pl b/misc/maintenance/update_authorities.pl old mode 100755 new mode 100644 index 6750ab1e4f8..e4bf74df067 --- a/misc/maintenance/update_authorities.pl +++ b/misc/maintenance/update_authorities.pl @@ -19,9 +19,9 @@ use Modern::Perl; -use Getopt::Long; -use List::MoreUtils qw/uniq/; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use List::MoreUtils qw( uniq ); +use Pod::Usage qw( pod2usage ); use Koha::Script; use C4::AuthoritiesMarc qw/AddAuthority DelAuthority GetAuthority merge/; diff --git a/misc/migration_tools/22_to_30/convert_to_utf8.pl b/misc/migration_tools/22_to_30/convert_to_utf8.pl old mode 100755 new mode 100644 index fbbff89c604..f14c13cdb5e --- a/misc/migration_tools/22_to_30/convert_to_utf8.pl +++ b/misc/migration_tools/22_to_30/convert_to_utf8.pl @@ -9,8 +9,7 @@ BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../../kohalib.pl" }; + eval { require "$FindBin::Bin/../../kohalib.pl" }; } use C4::Context; diff --git a/misc/migration_tools/22_to_30/export_Authorities.pl b/misc/migration_tools/22_to_30/export_Authorities.pl old mode 100755 new mode 100644 index 479981c94ef..2634b229fbe --- a/misc/migration_tools/22_to_30/export_Authorities.pl +++ b/misc/migration_tools/22_to_30/export_Authorities.pl @@ -3,15 +3,13 @@ use Modern::Perl; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../../kohalib.pl" }; + eval { require "$FindBin::Bin/../../kohalib.pl" }; } use C4::Context; #use MARC::File::XML(BinaryEncoding=>"utf8"); #use MARC::File::USMARC; -use MARC::Record; use C4::AuthoritiesMarc; -use POSIX; +use POSIX qw( close localtime sprintf time ); #MARC::File::XML::default_record_format("UNIMARCAUTH"); my $dbh = C4::Context->dbh; my $rq= $dbh->prepare(qq| diff --git a/misc/migration_tools/22_to_30/export_Authorities_xml.pl b/misc/migration_tools/22_to_30/export_Authorities_xml.pl old mode 100755 new mode 100644 index 6c917088a7e..2cf3cf96bc6 --- a/misc/migration_tools/22_to_30/export_Authorities_xml.pl +++ b/misc/migration_tools/22_to_30/export_Authorities_xml.pl @@ -3,14 +3,12 @@ use Modern::Perl; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../../kohalib.pl" }; + eval { require "$FindBin::Bin/../../kohalib.pl" }; } use C4::Context; use MARC::File::XML(BinaryEncoding=>"utf8"); -use MARC::Record; use C4::AuthoritiesMarc; -use POSIX; +use POSIX qw( close localtime open sprintf time ); MARC::File::XML::default_record_format("UNIMARCAUTH"); my $dbh = C4::Context->dbh; my $rq= $dbh->prepare(qq| diff --git a/misc/migration_tools/22_to_30/missing090field.pl b/misc/migration_tools/22_to_30/missing090field.pl old mode 100755 new mode 100644 index b54bf9285d1..4c39437163e --- a/misc/migration_tools/22_to_30/missing090field.pl +++ b/misc/migration_tools/22_to_30/missing090field.pl @@ -7,15 +7,13 @@ use strict; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../../kohalib.pl" }; + eval { require "$FindBin::Bin/../../kohalib.pl" }; } # Koha modules used use C4::Context; -use C4::Biblio; -use MARC::Record; +use C4::Biblio qw( GetMarcBiblio GetMarcFromKohaField ModBiblioMarc ); use MARC::File::USMARC; $|=1; 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 old mode 100755 new mode 100644 index f5e4b43288e..66c7bd11deb --- a/misc/migration_tools/22_to_30/move_marc_to_authheader.pl +++ b/misc/migration_tools/22_to_30/move_marc_to_authheader.pl @@ -7,12 +7,11 @@ use strict; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../../kohalib.pl" }; + eval { require "$FindBin::Bin/../../kohalib.pl" }; } use C4::Context; use C4::AuthoritiesMarc; -use MARC::Record; +use MARC::Record (); use MARC::File::XML ( BinaryEncoding => 'utf8' ); print "moving MARC record to marc_header table\n"; 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 old mode 100755 new mode 100644 index 386831e8b9c..c11e28f3098 --- a/misc/migration_tools/22_to_30/move_marc_to_biblioitems.pl +++ b/misc/migration_tools/22_to_30/move_marc_to_biblioitems.pl @@ -5,12 +5,10 @@ use Modern::Perl; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../../kohalib.pl" }; + eval { require "$FindBin::Bin/../../kohalib.pl" }; } use C4::Context; -use C4::Biblio; -use MARC::Record; +use MARC::Record (); use MARC::File::XML ( BinaryEncoding => 'utf8' ); print "moving MARC record to biblioitems table\n"; diff --git a/misc/migration_tools/22_to_30/rebuild_leader.pl b/misc/migration_tools/22_to_30/rebuild_leader.pl old mode 100755 new mode 100644 index 2d402c5bb51..44480cd4cbf --- a/misc/migration_tools/22_to_30/rebuild_leader.pl +++ b/misc/migration_tools/22_to_30/rebuild_leader.pl @@ -7,15 +7,13 @@ use strict; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../../kohalib.pl" }; + eval { require "$FindBin::Bin/../../kohalib.pl" }; } # Koha modules used use C4::Context; -use C4::Biblio; -use MARC::Record; +use C4::Biblio qw( ModBiblioMarc ); use MARC::File::USMARC; diff --git a/misc/migration_tools/22_to_30/rebuild_unimarc_100.pl b/misc/migration_tools/22_to_30/rebuild_unimarc_100.pl old mode 100755 new mode 100644 index 0988e5631d5..4fe08db96fd --- a/misc/migration_tools/22_to_30/rebuild_unimarc_100.pl +++ b/misc/migration_tools/22_to_30/rebuild_unimarc_100.pl @@ -7,15 +7,13 @@ use strict; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../../kohalib.pl" }; + eval { require "$FindBin::Bin/../../kohalib.pl" }; } # Koha modules used use C4::Context; -use C4::Biblio; -use MARC::Record; +use C4::Biblio qw( GetMarcBiblio ModBiblioMarc ); use MARC::File::USMARC; diff --git a/misc/migration_tools/buildCOUNTRY.pl b/misc/migration_tools/buildCOUNTRY.pl old mode 100755 new mode 100644 index af0bf216f21..9329ac0e595 --- a/misc/migration_tools/buildCOUNTRY.pl +++ b/misc/migration_tools/buildCOUNTRY.pl @@ -8,11 +8,10 @@ use strict; # Koha modules used use Koha::Script; use C4::Context; -use C4::Biblio; use C4::AuthoritiesMarc; -use Time::HiRes qw(gettimeofday); +use Time::HiRes qw( gettimeofday ); -use Getopt::Long; +use Getopt::Long qw( GetOptions ); my ( $fields, $number,$language) = ('',0); my ($version, $verbose, $test_parameter, $delete); GetOptions( diff --git a/misc/migration_tools/buildEDITORS.pl b/misc/migration_tools/buildEDITORS.pl old mode 100755 new mode 100644 index 8a25459e2a0..21499ab0e76 --- a/misc/migration_tools/buildEDITORS.pl +++ b/misc/migration_tools/buildEDITORS.pl @@ -6,15 +6,15 @@ use strict; # Koha modules used use MARC::File::USMARC; -use MARC::Record; +use MARC::Record (); use MARC::Batch; use Koha::Script; use C4::Context; use C4::Biblio qw( GetMarcBiblio ); use C4::AuthoritiesMarc; -use Time::HiRes qw(gettimeofday); +use Time::HiRes qw( gettimeofday ); -use Getopt::Long; +use Getopt::Long qw( GetOptions ); my ( $input_marc_file, $number) = ('',0); my ($version, $verbose, $test_parameter, $confirm,$delete); GetOptions( diff --git a/misc/migration_tools/buildLANG.pl b/misc/migration_tools/buildLANG.pl old mode 100755 new mode 100644 index b1174ab8d3b..bdef6dd9d31 --- a/misc/migration_tools/buildLANG.pl +++ b/misc/migration_tools/buildLANG.pl @@ -8,11 +8,10 @@ use strict; # Koha modules used use Koha::Script; use C4::Context; -use C4::Biblio; use C4::AuthoritiesMarc; -use Time::HiRes qw(gettimeofday); +use Time::HiRes qw( gettimeofday ); -use Getopt::Long; +use Getopt::Long qw( GetOptions ); my ( $fields, $number,$language) = ('',0); my ($version, $verbose, $test_parameter, $delete); GetOptions( diff --git a/misc/migration_tools/build_oai_sets.pl b/misc/migration_tools/build_oai_sets.pl old mode 100755 new mode 100644 index cdc577c86e6..5935aab479f --- a/misc/migration_tools/build_oai_sets.pl +++ b/misc/migration_tools/build_oai_sets.pl @@ -37,16 +37,24 @@ oai_sets_mappings, and then fill table oai_sets_biblios with builded infos. =cut use Modern::Perl; -use MARC::Record; +use MARC::Record (); use MARC::File::XML; -use List::MoreUtils qw/uniq/; -use Getopt::Std; +use List::MoreUtils qw( uniq ); +use Getopt::Std qw( getopts ); use Koha::Script; use C4::Context; use C4::Charset qw( StripNonXmlChars ); -use C4::Biblio qw( EmbedItemsInMarcBiblio ); -use C4::OAI::Sets; +use C4::Biblio (); +use C4::OAI::Sets qw( + AddOAISetsBiblios + CalcOAISetsBiblio + GetOAISet + GetOAISetBySpec + GetOAISets + GetOAISetsMappings + ModOAISetsBiblios +); my %opts; $Getopt::Std::STANDARD_HELP_VERSION = 1; diff --git a/misc/migration_tools/bulkmarcimport.pl b/misc/migration_tools/bulkmarcimport.pl old mode 100755 new mode 100644 index 7c3a6ff933f..88f644456a5 --- a/misc/migration_tools/bulkmarcimport.pl +++ b/misc/migration_tools/bulkmarcimport.pl @@ -6,33 +6,38 @@ use Modern::Perl; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } # Koha modules used use MARC::File::USMARC; use MARC::File::XML; -use MARC::Record; use MARC::Batch; -use MARC::Charset; -use Encode; +use Encode (); use Koha::Script; use C4::Context; -use C4::Biblio qw( GetMarcFromKohaField ModBiblio AddBiblio _strip_item_fields ModBiblioMarc ); +use C4::Biblio qw( + _strip_item_fields + AddBiblio + GetMarcFromKohaField + ModBiblio + ModBiblioMarc +); use C4::Koha; -use C4::Debug; +use C4::Debug qw( $debug ); use C4::Charset qw( MarcToUTF8Record SetUTF8Flag ); -use C4::Items qw( sub AddItemBatchFromMarc ); -use C4::MarcModificationTemplates; - -use YAML::XS; -use Unicode::Normalize; -use Time::HiRes qw(gettimeofday); -use Getopt::Long; -use IO::File; -use Pod::Usage; +use C4::Items qw( AddItemBatchFromMarc ); +use C4::MarcModificationTemplates qw( + GetModificationTemplates + ModifyRecordWithTemplate +); + +use YAML::XS (); +use Time::HiRes qw( gettimeofday ); +use Getopt::Long qw( GetOptions ); +use IO::File (); +use Pod::Usage qw( pod2usage ); use Koha::Biblios; use Koha::SearchEngine; diff --git a/misc/migration_tools/checkNonIndexedBiblios.pl b/misc/migration_tools/checkNonIndexedBiblios.pl old mode 100755 new mode 100644 index d03acbfc7a4..28b6a0018c6 --- a/misc/migration_tools/checkNonIndexedBiblios.pl +++ b/misc/migration_tools/checkNonIndexedBiblios.pl @@ -27,15 +27,13 @@ BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/kohalib.pl" }; + eval { require "$FindBin::Bin/kohalib.pl" }; } # Koha modules used -use MARC::Record; use Koha::Script; use C4::Context; -use Getopt::Long; +use Getopt::Long qw( GetOptions ); use Koha::SearchEngine::Search; diff --git a/misc/migration_tools/create_analytical_rel.pl b/misc/migration_tools/create_analytical_rel.pl old mode 100755 new mode 100644 index 65ebd2fc553..c0c559828d0 --- a/misc/migration_tools/create_analytical_rel.pl +++ b/misc/migration_tools/create_analytical_rel.pl @@ -5,16 +5,14 @@ use strict; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script; use C4::Context; use C4::Biblio qw( GetMarcBiblio ModBiblio ); -use C4::Items qw( sub ); use Koha::Items; -use Getopt::Long; +use Getopt::Long qw( GetOptions ); $| = 1; diff --git a/misc/migration_tools/ifla/update.pl b/misc/migration_tools/ifla/update.pl old mode 100755 new mode 100644 index a4e2d8d0faa..9653df29955 --- a/misc/migration_tools/ifla/update.pl +++ b/misc/migration_tools/ifla/update.pl @@ -19,12 +19,12 @@ use Modern::Perl; -use Date::Format; -use File::Basename; -use FindBin qw($Bin); -use Getopt::Long; +use Date::Format qw( time2str ); +use File::Basename qw( basename ); +use FindBin qw( $Bin ); +use Getopt::Long qw( GetOptions ); use Locale::PO; -use YAML::XS; +use YAML::XS (); use utf8; use Koha::Database; diff --git a/misc/migration_tools/import_lexile.pl b/misc/migration_tools/import_lexile.pl old mode 100755 new mode 100644 index eb8340e4b43..33280c235df --- a/misc/migration_tools/import_lexile.pl +++ b/misc/migration_tools/import_lexile.pl @@ -28,7 +28,7 @@ use utf8; use Modern::Perl; -use Getopt::Long; +use Getopt::Long qw( GetOptions ); use Text::CSV; use Koha::Script; @@ -45,8 +45,7 @@ BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } my $help; diff --git a/misc/migration_tools/koha-svc.pl b/misc/migration_tools/koha-svc.pl old mode 100755 new mode 100644 index 055c2383ef7..8efad38aa34 --- a/misc/migration_tools/koha-svc.pl +++ b/misc/migration_tools/koha-svc.pl @@ -20,8 +20,8 @@ use warnings; use strict; -use LWP::UserAgent; -use File::Slurp; +use LWP::UserAgent (); +use File::Slurp qw( read_file write_file ); if ( $#ARGV >= 3 && ! caller ) { # process command-line params only if not called as module! my ( $url, $user, $password, $biblionumber, $file ) = @ARGV; diff --git a/misc/migration_tools/rebuild_zebra.pl b/misc/migration_tools/rebuild_zebra.pl old mode 100755 new mode 100644 index 2bf6360110f..b760fa9ba02 --- a/misc/migration_tools/rebuild_zebra.pl +++ b/misc/migration_tools/rebuild_zebra.pl @@ -19,16 +19,16 @@ use Modern::Perl; use Koha::Script; use C4::Context; -use Getopt::Long; +use Getopt::Long qw( GetOptions ); use Fcntl qw(:flock); -use File::Temp qw/ tempdir /; -use File::Path; -use C4::Biblio qw( GetMarcFromKohaField GetXmlBiblio GetMarcBiblio _koha_marc_update_bib_ids ); +use File::Temp qw( tempdir ); +use File::Path qw( mkpath rmtree ); +use C4::Biblio qw( _koha_marc_update_bib_ids GetXmlBiblio ); use C4::AuthoritiesMarc; -use C4::Items qw( sub GetItemsInfo Item2Marc ); +use C4::Items qw( GetItemsInfo Item2Marc ); use Koha::RecordProcessor; use Koha::Caches; -use XML::LibXML; +use XML::LibXML (); use constant LOCK_FILENAME => 'rebuild..LCK'; diff --git a/misc/migration_tools/remove_unused_authorities.pl b/misc/migration_tools/remove_unused_authorities.pl old mode 100755 new mode 100644 index 63670b6a0bf..da57f88f42c --- a/misc/migration_tools/remove_unused_authorities.pl +++ b/misc/migration_tools/remove_unused_authorities.pl @@ -25,7 +25,7 @@ use Modern::Perl; use Koha::Script; use C4::Context; use C4::AuthoritiesMarc; -use Getopt::Long; +use Getopt::Long qw( GetOptions ); use Koha::SearchEngine::Search; diff --git a/misc/migration_tools/switch_marc21_series_info.pl b/misc/migration_tools/switch_marc21_series_info.pl old mode 100755 new mode 100644 index b145eaa35f1..65081afa593 --- a/misc/migration_tools/switch_marc21_series_info.pl +++ b/misc/migration_tools/switch_marc21_series_info.pl @@ -25,14 +25,13 @@ use warnings; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/../kohalib.pl" }; + eval { require "$FindBin::Bin/../kohalib.pl" }; } use Koha::Script; -use C4::Biblio qw( GetFrameworkCode GetMarcBiblio ModBiblio ModBiblioMarc ); +use C4::Biblio qw( GetFrameworkCode GetMarcBiblio ModBiblioMarc ); use C4::Context; -use Getopt::Long; +use Getopt::Long qw( GetOptions ); my $commit; my $add_links; diff --git a/misc/migration_tools/upgradeitems.pl b/misc/migration_tools/upgradeitems.pl old mode 100755 new mode 100644 index da612febff8..7ba79ae377d --- a/misc/migration_tools/upgradeitems.pl +++ b/misc/migration_tools/upgradeitems.pl @@ -5,7 +5,7 @@ use strict; use Koha::Script; use C4::Context; -use C4::Items qw( sub ModItemFromMarc ); +use C4::Items qw( ModItemFromMarc ); use C4::Biblio qw( GetMarcBiblio ); my $dbh=C4::Context->dbh; diff --git a/misc/mod_zebraqueue.pl b/misc/mod_zebraqueue.pl old mode 100755 new mode 100644 index cf128ef3556..ab1aa7b2b36 --- a/misc/mod_zebraqueue.pl +++ b/misc/mod_zebraqueue.pl @@ -20,8 +20,8 @@ use Modern::Perl; -use Getopt::Long; -use Pod::Usage; +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); use Koha::Script; use C4::Biblio qw( ModZebra ); diff --git a/misc/perlmodule_ls.pl b/misc/perlmodule_ls.pl old mode 100755 new mode 100644 diff --git a/misc/perlmodule_rm.pl b/misc/perlmodule_rm.pl old mode 100755 new mode 100644 diff --git a/misc/recreateIssueStatistics.pl b/misc/recreateIssueStatistics.pl old mode 100755 new mode 100644 index a710c353c76..859cf02a5e2 --- a/misc/recreateIssueStatistics.pl +++ b/misc/recreateIssueStatistics.pl @@ -25,9 +25,7 @@ use warnings; use Koha::Script; use C4::Context; -use C4::Items qw( sub ); -use Data::Dumper; -use Getopt::Long; +use Getopt::Long qw( GetOptions ); use Koha::Items; my $dbh = C4::Context->dbh; diff --git a/misc/sax_parser_print.pl b/misc/sax_parser_print.pl old mode 100755 new mode 100644 diff --git a/misc/sax_parser_test.pl b/misc/sax_parser_test.pl old mode 100755 new mode 100644 index fb56de1174f..159cdbb17cc --- a/misc/sax_parser_test.pl +++ b/misc/sax_parser_test.pl @@ -3,8 +3,8 @@ use strict; use warnings; -use XML::SAX; -use Encode; +use XML::SAX (); +use Encode qw( encode_utf8 ); my $parser = XML::SAX::ParserFactory->parser( Handler => MySAXHandler->new diff --git a/misc/search_tools/export_elasticsearch_mappings.pl b/misc/search_tools/export_elasticsearch_mappings.pl old mode 100755 new mode 100644 index 6e2b158a79a..2cee2840547 --- a/misc/search_tools/export_elasticsearch_mappings.pl +++ b/misc/search_tools/export_elasticsearch_mappings.pl @@ -52,7 +52,7 @@ Full documentation. =cut use Modern::Perl; -use Encode; +use Encode (); use Koha::Script; use Koha::Database; @@ -60,9 +60,9 @@ use Koha::SearchFields; use Koha::SearchMarcMaps; use Koha::SearchEngine::Elasticsearch; -use YAML::XS; -use Getopt::Long; -use Pod::Usage; +use YAML::XS (); +use Getopt::Long qw( GetOptions ); +use Pod::Usage qw( pod2usage ); my $type = ''; my $man; diff --git a/misc/search_tools/rebuild_elasticsearch.pl b/misc/search_tools/rebuild_elasticsearch.pl old mode 100755 new mode 100644 index 3b25709a76f..337ac19dd2d --- a/misc/search_tools/rebuild_elasticsearch.pl +++ b/misc/search_tools/rebuild_elasticsearch.pl @@ -112,7 +112,7 @@ Full documentation. =cut use autodie; -use Getopt::Long; +use Getopt::Long qw( GetOptions ); use Koha::Script; use C4::Context; use Koha::MetadataRecord::Authority; @@ -120,10 +120,9 @@ use Koha::BiblioUtils; use Koha::SearchEngine::Elasticsearch; use Koha::SearchEngine::Elasticsearch::Indexer; use MARC::Field; -use MARC::Record; use Modern::Perl; -use Pod::Usage; -use Try::Tiny; +use Pod::Usage qw( pod2usage ); +use Try::Tiny qw( catch try ); my $verbose = 0; my $commit = 5000; diff --git a/misc/sip_cli_emulator.pl b/misc/sip_cli_emulator.pl old mode 100755 new mode 100644 index 00a54a643fb..87add2b7fe1 --- a/misc/sip_cli_emulator.pl +++ b/misc/sip_cli_emulator.pl @@ -20,11 +20,11 @@ use Modern::Perl; use Socket qw(:crlf); -use IO::Socket::INET; -use Getopt::Long; +use IO::Socket::INET (); +use Getopt::Long qw( GetOptions ); -use C4::SIP::Sip qw( timestamp ); -use C4::SIP::Sip qw( timestamp ); +use C4::SIP::Sip (); +use C4::SIP::Sip (); use constant { LANGUAGE => '001' }; diff --git a/misc/stage_file.pl b/misc/stage_file.pl old mode 100755 new mode 100644 index 1970ce8e571..a7578d08b94 --- a/misc/stage_file.pl +++ b/misc/stage_file.pl @@ -23,16 +23,15 @@ use Modern::Perl; BEGIN { # find Koha's Perl modules # test carefully before changing this - use FindBin; - eval { require "$FindBin::Bin/kohalib.pl" }; + eval { require "$FindBin::Bin/kohalib.pl" }; } use Koha::Script; use C4::Context; use C4::ImportBatch qw( sub RecordsFromISO2709File RecordsFromMARCXMLFile BatchStageMarcRecords SetImportBatchMatcher SetImportBatchOverlayAction SetImportBatchNoMatchAction SetImportBatchItemAction BatchFindDuplicates ); use C4::Matcher; -use C4::MarcModificationTemplates; -use Getopt::Long; +use C4::MarcModificationTemplates qw( GetModificationTemplates ); +use Getopt::Long qw( GetOptions ); $| = 1; diff --git a/misc/translator/tmpl_process3.pl b/misc/translator/tmpl_process3.pl old mode 100755 new mode 100644 index 3c046189150..a51d063118e --- a/misc/translator/tmpl_process3.pl +++ b/misc/translator/tmpl_process3.pl @@ -4,7 +4,6 @@ # Parts copyright 2003-2004 Jerome Vizcaino # Parts copyright 2004 Ambrose Li -use FindBin; use lib $FindBin::Bin; =head1 NAME @@ -16,8 +15,8 @@ using gettext-compatible translation files use strict; #use warnings; FIXME - Bug 2505 -use File::Basename; -use Getopt::Long; +use File::Basename qw( fileparse ); +use Getopt::Long qw( GetOptions ); use Locale::PO; use File::Temp qw( :POSIX ); use TmplTokenizer; diff --git a/misc/translator/xgettext.pl b/misc/translator/xgettext.pl old mode 100755 new mode 100644 index e04c5298634..468412faa4f --- a/misc/translator/xgettext.pl +++ b/misc/translator/xgettext.pl @@ -21,13 +21,12 @@ xgettext.pl - xgettext(1)-like interface for .tt strings extraction =cut -use FindBin; use lib $FindBin::Bin; use strict; use warnings; -use Getopt::Long; -use POSIX; +use Getopt::Long qw( GetOptions ); +use POSIX qw( close exit localtime open printf time ); use Locale::PO; use TmplTokenizer; use VerboseWarnings; diff --git a/misc/z3950_responder.pl b/misc/z3950_responder.pl old mode 100755 new mode 100644 index 48609ddce84..fa3c0074c00 --- a/misc/z3950_responder.pl +++ b/misc/z3950_responder.pl @@ -19,10 +19,9 @@ use Modern::Perl; -use Carp; -use File::Basename; +use File::Basename qw( fileparse ); use Getopt::Long qw(:config no_ignore_case); -use Pod::Usage; +use Pod::Usage qw( pod2usage ); use Koha::Config; use Koha::Z3950Responder; diff --git a/offline_circ/download.pl b/offline_circ/download.pl old mode 100755 new mode 100644 index c80a2260137..09d7ba2282c --- a/offline_circ/download.pl +++ b/offline_circ/download.pl @@ -19,11 +19,10 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use JSON; +use JSON qw( to_json ); use C4::Auth qw( checkauth ); use C4::Output; use C4::Context; -use C4::Koha; my $query = CGI->new; checkauth( $query, undef, { circulate => "circulate_remaining_permissions" }, diff --git a/offline_circ/enqueue_koc.pl b/offline_circ/enqueue_koc.pl old mode 100755 new mode 100644 index 721798483a6..1618e2d03ed --- a/offline_circ/enqueue_koc.pl +++ b/offline_circ/enqueue_koc.pl @@ -23,19 +23,15 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Context; -use C4::Biblio; use C4::Accounts; use C4::Circulation qw( AddOfflineOperation ); -use C4::Items qw( sub ); use C4::Members; use C4::Stats; use Koha::Checkouts; use Koha::UploadedFiles; use Koha::Items; -use Date::Calc qw( Add_Delta_Days Date_to_Days ); use constant DEBUG => 0; diff --git a/offline_circ/list.pl b/offline_circ/list.pl old mode 100755 new mode 100644 index f25d4e6c96b..252dc8594b8 --- a/offline_circ/list.pl +++ b/offline_circ/list.pl @@ -23,11 +23,9 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Context; use C4::Circulation qw( GetOfflineOperations GetOfflineOperation ); use C4::Members; -use C4::Biblio; use Koha::Patrons; use Koha::Items; diff --git a/offline_circ/process.pl b/offline_circ/process.pl old mode 100755 new mode 100644 diff --git a/offline_circ/process_koc.pl b/offline_circ/process_koc.pl old mode 100755 new mode 100644 index 577e13fa4b5..9b482538e77 --- a/offline_circ/process_koc.pl +++ b/offline_circ/process_koc.pl @@ -21,16 +21,13 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Carp; use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Context; -use C4::Biblio; use C4::Accounts; use C4::Circulation qw( barcodedecode GetOpenIssue AddRenewal AddIssue MarkIssueReturned ); -use C4::Items qw( sub ModDateLastSeen ); +use C4::Items qw( ModDateLastSeen ); use C4::Members; use C4::Stats; use C4::BackgroundJob; @@ -39,7 +36,7 @@ use Koha::Account; use Koha::Checkouts; use Koha::Patrons; -use Date::Calc qw( Add_Delta_Days Date_to_Days ); +use Date::Calc qw( Date_to_Days ); use constant DEBUG => 0; diff --git a/offline_circ/service.pl b/offline_circ/service.pl old mode 100755 new mode 100644 index 3ed1c26457b..00ae314c0fd --- a/offline_circ/service.pl +++ b/offline_circ/service.pl @@ -23,7 +23,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( check_api_auth check_cookie_auth ); use C4::Circulation qw( AddOfflineOperation ProcessOfflineOperation ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use DateTime::TimeZone; my $cgi = CGI->new; diff --git a/opac/clubs/clubs-tab.pl b/opac/clubs/clubs-tab.pl old mode 100755 new mode 100644 index a3243d4d52a..f79eadf9924 --- a/opac/clubs/clubs-tab.pl +++ b/opac/clubs/clubs-tab.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/opac/clubs/enroll.pl b/opac/clubs/enroll.pl old mode 100755 new mode 100644 index a71990196fd..1fa58b070be --- a/opac/clubs/enroll.pl +++ b/opac/clubs/enroll.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/opac/errors/400.pl b/opac/errors/400.pl old mode 100755 new mode 100644 index b069697b17d..30a949390e7 --- a/opac/errors/400.pl +++ b/opac/errors/400.pl @@ -21,7 +21,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_with_http_headers ); use C4::Context; -use List::MoreUtils qw(any); +use List::MoreUtils qw( any ); my $query = CGI->new; my $admin = C4::Context->preference('KohaAdminEmailAddress'); diff --git a/opac/errors/401.pl b/opac/errors/401.pl old mode 100755 new mode 100644 index a4dbd1e63d4..a88349f989a --- a/opac/errors/401.pl +++ b/opac/errors/401.pl @@ -21,7 +21,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_with_http_headers ); use C4::Context; -use List::MoreUtils qw(any); +use List::MoreUtils qw( any ); my $query = CGI->new; my $admin = C4::Context->preference('KohaAdminEmailAddress'); diff --git a/opac/errors/402.pl b/opac/errors/402.pl old mode 100755 new mode 100644 index 271afe0c9cd..063b0fecb77 --- a/opac/errors/402.pl +++ b/opac/errors/402.pl @@ -21,7 +21,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_with_http_headers ); use C4::Context; -use List::MoreUtils qw(any); +use List::MoreUtils qw( any ); my $query = CGI->new; my $admin = C4::Context->preference('KohaAdminEmailAddress'); diff --git a/opac/errors/403.pl b/opac/errors/403.pl old mode 100755 new mode 100644 index c305b9f92b5..35d70f2b912 --- a/opac/errors/403.pl +++ b/opac/errors/403.pl @@ -21,7 +21,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_with_http_headers ); use C4::Context; -use List::MoreUtils qw(any); +use List::MoreUtils qw( any ); my $query = CGI->new; my $admin = C4::Context->preference('KohaAdminEmailAddress'); diff --git a/opac/errors/404.pl b/opac/errors/404.pl old mode 100755 new mode 100644 index 60128b72d4c..2d1e60f95a2 --- a/opac/errors/404.pl +++ b/opac/errors/404.pl @@ -21,7 +21,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_with_http_headers ); use C4::Context; -use List::MoreUtils qw(any); +use List::MoreUtils qw( any ); my $query = CGI->new; my $admin = C4::Context->preference('KohaAdminEmailAddress'); diff --git a/opac/errors/500.pl b/opac/errors/500.pl old mode 100755 new mode 100644 index f269ab29966..663ca6a6680 --- a/opac/errors/500.pl +++ b/opac/errors/500.pl @@ -21,7 +21,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_with_http_headers ); use C4::Context; -use List::MoreUtils qw(any); +use List::MoreUtils qw( any ); my $query = CGI->new; my $admin = C4::Context->preference('KohaAdminEmailAddress'); diff --git a/opac/external/overdrive/auth.pl b/opac/external/overdrive/auth.pl old mode 100755 new mode 100644 index f534c24885c..bfeb9b22556 --- a/opac/external/overdrive/auth.pl +++ b/opac/external/overdrive/auth.pl @@ -20,9 +20,8 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use URI; -use URI::Escape; -use C4::Auth qw(checkauth); +use URI (); +use URI::Escape qw( uri_escape ); use Koha::Logger; use Koha::ExternalContent::OverDrive; diff --git a/opac/ilsdi.pl b/opac/ilsdi.pl old mode 100755 new mode 100644 index 9b6c2fe67d0..83a254726e0 --- a/opac/ilsdi.pl +++ b/opac/ilsdi.pl @@ -24,10 +24,10 @@ use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Context; -use List::MoreUtils qw(any); -use XML::Simple; +use List::MoreUtils qw( any ); +use XML::Simple qw( XMLout ); use CGI qw ( -utf8 ); -use Net::Netmask; +use Net::Netmask (); =head1 DLF ILS-DI for Koha diff --git a/opac/maintenance.pl b/opac/maintenance.pl old mode 100755 new mode 100644 diff --git a/opac/oai.pl b/opac/oai.pl old mode 100755 new mode 100644 diff --git a/opac/opac-ISBDdetail.pl b/opac/opac-ISBDdetail.pl old mode 100755 new mode 100644 index d43626b6b19..a91c0a6fe00 --- a/opac/opac-ISBDdetail.pl +++ b/opac/opac-ISBDdetail.pl @@ -45,12 +45,22 @@ use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( parametrized_url output_html_with_http_headers ); use CGI qw ( -utf8 ); -use C4::Biblio qw( TransformMarcToKoha GetISBDView CountItemsIssued GetMarcControlnumber GetMarcISSN ); -use C4::Items qw( sub ); +use C4::Biblio qw( + CountItemsIssued + GetISBDView + GetMarcControlnumber + GetMarcISSN + TransformMarcToKoha +); use C4::Reserves; use C4::Acquisition; use C4::Serials qw( CountSubscriptionFromBiblionumber SearchSubscriptions GetLatestSerials ); -use C4::Koha qw( GetNormalizedUPC GetNormalizedEAN GetNormalizedOCLCNumber GetNormalizedISBN ); +use C4::Koha qw( + GetNormalizedEAN + GetNormalizedISBN + GetNormalizedOCLCNumber + GetNormalizedUPC +); use Koha::CirculationRules; use Koha::ItemTypes; use Koha::Patrons; diff --git a/opac/opac-MARCdetail.pl b/opac/opac-MARCdetail.pl old mode 100755 new mode 100644 index a60012bec9e..838185f8d44 --- a/opac/opac-MARCdetail.pl +++ b/opac/opac-MARCdetail.pl @@ -49,21 +49,28 @@ use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( parametrized_url output_html_with_http_headers ); use CGI qw ( -utf8 ); -use MARC::Record; -use C4::Biblio qw( GetMarcBiblio GetMarcStructure GetMarcFromKohaField CountItemsIssued GetAuthorisedValueDesc TransformMarcToKoha GetMarcControlnumber GetMarcISSN ); -use C4::Items qw( sub ); +use C4::Biblio qw( + CountItemsIssued + GetAuthorisedValueDesc + GetMarcBiblio + GetMarcControlnumber + GetMarcFromKohaField + GetMarcISSN + GetMarcStructure + TransformMarcToKoha +); use C4::Reserves; use C4::Members; use C4::Acquisition; -use C4::Koha qw( display_marc_indicators GetNormalizedISBN ); -use List::MoreUtils qw( any uniq ); +use C4::Koha qw( GetNormalizedISBN ); +use List::MoreUtils qw( uniq ); use Koha::Biblios; use Koha::CirculationRules; use Koha::Items; use Koha::ItemTypes; use Koha::Patrons; use Koha::RecordProcessor; -use Koha::DateUtils; +use Koha::DateUtils qw( output_pref ); my $query = CGI->new(); diff --git a/opac/opac-account-pay-return.pl b/opac/opac-account-pay-return.pl old mode 100755 new mode 100644 index bdfbcfcb1a6..35b74ec1a07 --- a/opac/opac-account-pay-return.pl +++ b/opac/opac-account-pay-return.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( checkauth ); use Koha::Plugins::Handler; diff --git a/opac/opac-account-pay.pl b/opac/opac-account-pay.pl old mode 100755 new mode 100644 index 445403fe061..87db9ee496a --- a/opac/opac-account-pay.pl +++ b/opac/opac-account-pay.pl @@ -21,10 +21,7 @@ use utf8; use Modern::Perl; -use CGI; -use HTTP::Request::Common; -use LWP::UserAgent; -use URI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output; diff --git a/opac/opac-account.pl b/opac/opac-account.pl old mode 100755 new mode 100644 diff --git a/opac/opac-addbybiblionumber.pl b/opac/opac-addbybiblionumber.pl old mode 100755 new mode 100644 index 16f5eebfd42..176a1c4fd2d --- a/opac/opac-addbybiblionumber.pl +++ b/opac/opac-addbybiblionumber.pl @@ -21,7 +21,6 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use C4::Biblio; use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); diff --git a/opac/opac-alert-subscribe.pl b/opac/opac-alert-subscribe.pl old mode 100755 new mode 100644 index 11f4cc53dd7..6f6c3fe1c8c --- a/opac/opac-alert-subscribe.pl +++ b/opac/opac-alert-subscribe.pl @@ -23,8 +23,6 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Context; -use C4::Koha; -use C4::Letters; use C4::Serials qw( GetSubscription ); diff --git a/opac/opac-article-request-cancel.pl b/opac/opac-article-request-cancel.pl old mode 100755 new mode 100644 diff --git a/opac/opac-authorities-home.pl b/opac/opac-authorities-home.pl old mode 100755 new mode 100644 index 1155000a504..dc1f129429e --- a/opac/opac-authorities-home.pl +++ b/opac/opac-authorities-home.pl @@ -21,7 +21,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use URI::Escape; +use URI::Escape qw( uri_escape_utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Context; diff --git a/opac/opac-authoritiesdetail.pl b/opac/opac-authoritiesdetail.pl old mode 100755 new mode 100644 index 83fb363050c..33ef73b2758 --- a/opac/opac-authoritiesdetail.pl +++ b/opac/opac-authoritiesdetail.pl @@ -44,8 +44,7 @@ use C4::Biblio qw( GetMarcUrls ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use CGI qw ( -utf8 ); -use MARC::Record; -use C4::Koha qw( display_marc_indicators ); +use C4::Koha (); use Koha::Authorities; use Koha::Authority::Types; diff --git a/opac/opac-basket.pl b/opac/opac-basket.pl old mode 100755 new mode 100644 index 6997a6bfda3..ef4a25700f3 --- a/opac/opac-basket.pl +++ b/opac/opac-basket.pl @@ -20,8 +20,16 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Koha; -use C4::Biblio qw( GetBiblioData GetMarcBiblio GetFrameworkCode GetMarcAuthors GetMarcSubjects GetMarcSeries GetMarcUrls ); -use C4::Items qw( sub GetItemsInfo GetHiddenItemnumbers ); +use C4::Biblio qw( + GetBiblioData + GetFrameworkCode + GetMarcAuthors + GetMarcBiblio + GetMarcSeries + GetMarcSubjects + GetMarcUrls +); +use C4::Items qw( GetHiddenItemnumbers GetItemsInfo ); use C4::Circulation qw( GetTransfers ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/opac/opac-blocked.pl b/opac/opac-blocked.pl old mode 100755 new mode 100644 diff --git a/opac/opac-browse.pl b/opac/opac-browse.pl old mode 100755 new mode 100644 index 2ec62186b66..bde1e716aad --- a/opac/opac-browse.pl +++ b/opac/opac-browse.pl @@ -31,7 +31,7 @@ use Koha::SearchEngine::Elasticsearch::Browse; use Koha::SearchEngine::Elasticsearch::QueryBuilder; use Koha::SearchEngine::Elasticsearch::Search; -use JSON; +use JSON qw( to_json ); use Unicode::Collate; my $query = CGI->new; diff --git a/opac/opac-browser.pl b/opac/opac-browser.pl old mode 100755 new mode 100644 index 443c25ee19f..42c645eaeb4 --- a/opac/opac-browser.pl +++ b/opac/opac-browser.pl @@ -30,7 +30,6 @@ use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use CGI qw ( -utf8 ); -use C4::Biblio; my $query = CGI->new; diff --git a/opac/opac-changelanguage.pl b/opac/opac-changelanguage.pl old mode 100755 new mode 100644 diff --git a/opac/opac-course-details.pl b/opac/opac-course-details.pl old mode 100755 new mode 100644 index 95915b4aa45..26a38ee62f8 --- a/opac/opac-course-details.pl +++ b/opac/opac-course-details.pl @@ -24,7 +24,6 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Koha; use C4::CourseReserves qw( GetCourse GetCourseReserve GetCourseReserves ); diff --git a/opac/opac-course-reserves.pl b/opac/opac-course-reserves.pl old mode 100755 new mode 100644 diff --git a/opac/opac-detail.pl b/opac/opac-detail.pl old mode 100755 new mode 100644 index 7d593759f6c..eeddc5d1f77 --- a/opac/opac-detail.pl +++ b/opac/opac-detail.pl @@ -25,27 +25,48 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Acquisition qw( SearchOrders ); use C4::Auth qw( get_template_and_user get_session ); -use C4::Koha qw( GetNormalizedEAN getitemtypeimagelocation GetNormalizedUPC GetNormalizedOCLCNumber GetNormalizedISBN ); +use C4::Koha qw( + getitemtypeimagelocation + GetNormalizedEAN + GetNormalizedISBN + GetNormalizedOCLCNumber + GetNormalizedUPC +); use C4::Serials qw( CountSubscriptionFromBiblionumber SearchSubscriptions GetLatestSerials ); use C4::Output qw( parametrized_url output_html_with_http_headers ); -use C4::Biblio qw( GetMarcBiblio GetBiblioData CountItemsIssued GetMarcISBN GetMarcAuthors GetMarcSubjects GetMarcSeries GetMarcUrls GetMarcControlnumber GetMarcISSN ); -use C4::Items qw( GetItemsInfo GetHiddenItemnumbers sub ); +use C4::Biblio qw( + CountItemsIssued + GetBiblioData + GetMarcAuthors + GetMarcBiblio + GetMarcControlnumber + GetMarcISBN + GetMarcISSN + GetMarcSeries + GetMarcSubjects + GetMarcUrls +); +use C4::Items qw( GetHiddenItemnumbers GetItemsInfo ); use C4::Circulation qw( GetTransfers ); -use C4::Tags qw( get_tags get_tag ); +use C4::Tags qw( get_tags ); use C4::XISBN qw( get_xisbns ); -use C4::External::Amazon; +use C4::External::Amazon qw( get_amazon_tld ); use C4::External::BakerTaylor qw( image_url link_url ); -use C4::External::Syndetics qw(get_syndetics_index get_syndetics_summary get_syndetics_toc get_syndetics_excerpt get_syndetics_reviews get_syndetics_anotes ); +use C4::External::Syndetics qw( + get_syndetics_anotes + get_syndetics_excerpt + get_syndetics_index + get_syndetics_reviews + get_syndetics_summary + get_syndetics_toc +); use C4::Members; use C4::XSLT; use C4::ShelfBrowser qw( GetNearbyItems ); use C4::Reserves qw( GetReserveStatus ); use C4::Charset qw( SetUTF8Flag ); -use C4::Letters; -use MARC::Record; use MARC::Field; -use List::MoreUtils qw/any none/; -use Koha::DateUtils; +use List::MoreUtils qw( any ); use C4::HTML5Media; use C4::CourseReserves qw( GetItemCourseReservesInfo ); @@ -63,7 +84,6 @@ use Koha::Ratings; use Koha::Reviews; use Koha::SearchEngine::Search; -use Try::Tiny; my $query = CGI->new(); @@ -228,7 +248,7 @@ my $session = get_session($query->cookie("CGISESSID")); my %paging = (previous => {}, next => {}); if ($session->param('busc')) { use C4::Search; - use URI::Escape; + use URI::Escape qw( uri_escape_utf8 uri_unescape ); # Rebuild the string to store on session # param value is URI encoded and params separator is HTML encode (&) diff --git a/opac/opac-discharge.pl b/opac/opac-discharge.pl old mode 100755 new mode 100644 index c773568e343..546fadc2331 --- a/opac/opac-discharge.pl +++ b/opac/opac-discharge.pl @@ -18,17 +18,14 @@ # along with Koha; if not, see . use Modern::Perl; -use Carp; +use Carp qw( carp ); use C4::Auth qw( get_template_and_user ); use CGI qw( -utf8 ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::Log; -use C4::Debug; use Koha::Patrons; use Koha::Patron::Discharge; -use Koha::DateUtils; my $input = CGI->new; diff --git a/opac/opac-downloadcart.pl b/opac/opac-downloadcart.pl old mode 100755 new mode 100644 index 1641627bb37..ade1a53770a --- a/opac/opac-downloadcart.pl +++ b/opac/opac-downloadcart.pl @@ -20,14 +20,13 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Encode qw(encode); +use Encode qw( encode ); use C4::Auth qw( get_template_and_user ); -use C4::Biblio qw( GetMarcBiblio GetFrameworkCode GetISBDView ); -use C4::Items; +use C4::Biblio qw( GetFrameworkCode GetISBDView GetMarcBiblio ); use C4::Output qw( output_html_with_http_headers ); use C4::Record; -use C4::Ris; +use C4::Ris qw( marc2ris ); use Koha::CsvProfiles; use Koha::RecordProcessor; diff --git a/opac/opac-downloadshelf.pl b/opac/opac-downloadshelf.pl old mode 100755 new mode 100644 index 9cf72399368..31da711328d --- a/opac/opac-downloadshelf.pl +++ b/opac/opac-downloadshelf.pl @@ -20,14 +20,12 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Encode qw(encode); use C4::Auth qw( get_template_and_user ); -use C4::Biblio qw( GetMarcBiblio GetFrameworkCode GetISBDView ); -use C4::Items; +use C4::Biblio qw( GetFrameworkCode GetISBDView GetMarcBiblio ); use C4::Output qw( output_html_with_http_headers ); use C4::Record; -use C4::Ris; +use C4::Ris qw( marc2ris ); use Koha::CsvProfiles; use Koha::RecordProcessor; use Koha::Virtualshelves; diff --git a/opac/opac-export.pl b/opac/opac-export.pl old mode 100755 new mode 100644 index da71d5080a4..d816ded995d --- a/opac/opac-export.pl +++ b/opac/opac-export.pl @@ -22,10 +22,15 @@ use Modern::Perl; use C4::Record; use C4::Auth; use C4::Output; -use C4::Biblio qw( GetMarcBiblio GetMarcControlnumber GetFrameworkCode GetISBDView ); +use C4::Biblio qw( + GetFrameworkCode + GetISBDView + GetMarcBiblio + GetMarcControlnumber +); use CGI qw ( -utf8 ); use C4::Auth; -use C4::Ris; +use C4::Ris qw( marc2ris ); use Koha::RecordProcessor; my $query = CGI->new; diff --git a/opac/opac-holdshistory.pl b/opac/opac-holdshistory.pl old mode 100755 new mode 100644 diff --git a/opac/opac-ics.pl b/opac/opac-ics.pl old mode 100755 new mode 100644 index 4cd1a6ac1ee..c66b5d70bac --- a/opac/opac-ics.pl +++ b/opac/opac-ics.pl @@ -27,13 +27,12 @@ use Data::ICal::Entry::Event; use DateTime; use DateTime::Format::ICal; use DateTime::Event::ICal; -use URI; +use URI (); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Circulation; use C4::Members; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); my $query = CGI->new; my ( $template, $borrowernumber, $cookie ) = get_template_and_user( diff --git a/opac/opac-idref.pl b/opac/opac-idref.pl old mode 100755 new mode 100644 index 47f3867e9ef..1a57b1c7099 --- a/opac/opac-idref.pl +++ b/opac/opac-idref.pl @@ -19,11 +19,10 @@ use Modern::Perl; -use CGI; -use LWP::UserAgent; -use HTTP::Request::Common; -use JSON; -use Encode; +use CGI (); +use LWP::UserAgent (); +use JSON qw( from_json ); +use Encode (); use C4::Auth qw( get_template_and_user ); use C4::Context; diff --git a/opac/opac-illrequests.pl b/opac/opac-illrequests.pl old mode 100755 new mode 100644 index e619707451e..afdc4546e56 --- a/opac/opac-illrequests.pl +++ b/opac/opac-illrequests.pl @@ -23,7 +23,6 @@ use JSON qw( encode_json ); use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Output qw( output_html_with_http_headers ); use Koha::Illrequest::Config; diff --git a/opac/opac-image.pl b/opac/opac-image.pl old mode 100755 new mode 100644 diff --git a/opac/opac-imageviewer.pl b/opac/opac-imageviewer.pl old mode 100755 new mode 100644 index e133c93cc59..bacbf848a7c --- a/opac/opac-imageviewer.pl +++ b/opac/opac-imageviewer.pl @@ -21,7 +21,6 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Biblio; use C4::Output qw( output_html_with_http_headers ); use Koha::Biblios; diff --git a/opac/opac-issue-note.pl b/opac/opac-issue-note.pl old mode 100755 new mode 100644 index a8a49ac4277..cd19d20e98b --- a/opac/opac-issue-note.pl +++ b/opac/opac-issue-note.pl @@ -25,10 +25,9 @@ use C4::Context; use C4::Scrubber; use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Biblio; -use C4::Letters qw( GetPreparedLetter EnqueueLetter ); +use C4::Letters (); use Koha::Checkouts; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::Patrons; my $query = CGI->new; diff --git a/opac/opac-library.pl b/opac/opac-library.pl old mode 100755 new mode 100644 diff --git a/opac/opac-main.pl b/opac/opac-main.pl old mode 100755 new mode 100644 index 159f30fc006..2e378031ac6 --- a/opac/opac-main.pl +++ b/opac/opac-main.pl @@ -22,8 +22,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::NewsChannels; # GetNewsToDisplay -use C4::Languages qw(getTranslatedLanguages accept_language); +use C4::NewsChannels qw( GetNewsToDisplay ); # GetNewsToDisplay use Koha::Quotes; use C4::Members; use C4::Overdues qw( checkoverdues ); diff --git a/opac/opac-memberentry.pl b/opac/opac-memberentry.pl old mode 100755 new mode 100644 index ccc3b3c2395..269e8a013d0 --- a/opac/opac-memberentry.pl +++ b/opac/opac-memberentry.pl @@ -19,7 +19,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); use Digest::MD5 qw( md5_base64 md5_hex ); -use JSON; +use JSON qw( to_json ); use List::MoreUtils qw( any each_array uniq ); use String::Random qw( random_string ); @@ -28,14 +28,14 @@ use C4::Output qw( output_html_with_http_headers ); use C4::Context; use C4::Members qw( get_cardnumber_length checkcardnumber ); use C4::Form::MessagingPreferences; -use Koha::AuthUtils qw( generate_password is_password_valid ); +use Koha::AuthUtils (); use Koha::Patrons; use Koha::Patron::Consent; use Koha::Patron::Modification; use Koha::Patron::Modifications; use C4::Scrubber; use Email::Valid; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Libraries; use Koha::Patron::Attribute::Types; use Koha::Patron::Attributes; diff --git a/opac/opac-messaging.pl b/opac/opac-messaging.pl old mode 100755 new mode 100644 index 380117d324b..d189e39e548 --- a/opac/opac-messaging.pl +++ b/opac/opac-messaging.pl @@ -23,7 +23,6 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Context; -use C4::Koha; use C4::Circulation; use C4::Output qw( output_html_with_http_headers ); use C4::Members; diff --git a/opac/opac-modrequest-suspend.pl b/opac/opac-modrequest-suspend.pl old mode 100755 new mode 100644 diff --git a/opac/opac-modrequest.pl b/opac/opac-modrequest.pl old mode 100755 new mode 100644 diff --git a/opac/opac-mymessages.pl b/opac/opac-mymessages.pl old mode 100755 new mode 100644 index 75a6ba58694..974e0b42fb8 --- a/opac/opac-mymessages.pl +++ b/opac/opac-mymessages.pl @@ -23,8 +23,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Context; -use C4::Koha; -use C4::Letters qw( GetRSSMessages ); +use C4::Letters (); use C4::Output qw( output_html_with_http_headers ); my $query = CGI->new(); diff --git a/opac/opac-news-rss.pl b/opac/opac-news-rss.pl old mode 100755 new mode 100644 index 7ba7501ba2c..3840d449513 --- a/opac/opac-news-rss.pl +++ b/opac/opac-news-rss.pl @@ -19,11 +19,10 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::NewsChannels; # GetNewsToDisplay -use C4::Languages qw(getTranslatedLanguages accept_language); +use C4::NewsChannels qw( GetNewsToDisplay ); # GetNewsToDisplay my $input = CGI->new; my $dbh = C4::Context->dbh; diff --git a/opac/opac-overdrive-search.pl b/opac/opac-overdrive-search.pl old mode 100755 new mode 100644 diff --git a/opac/opac-passwd.pl b/opac/opac-passwd.pl old mode 100755 new mode 100644 index d0479d33a94..493695753f4 --- a/opac/opac-passwd.pl +++ b/opac/opac-passwd.pl @@ -29,7 +29,7 @@ use C4::Members; use C4::Output qw( output_html_with_http_headers ); use Koha::Patrons; -use Try::Tiny; +use Try::Tiny qw( catch try ); my $query = CGI->new; diff --git a/opac/opac-password-recovery.pl b/opac/opac-password-recovery.pl old mode 100755 new mode 100644 index 73a2496d15c..4d46fa9b365 --- a/opac/opac-password-recovery.pl +++ b/opac/opac-password-recovery.pl @@ -1,19 +1,23 @@ #!/usr/bin/perl use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Output qw( output_html_with_http_headers ); use C4::Context; -use Koha::Patron::Password::Recovery - qw(SendPasswordRecoveryEmail ValidateBorrowernumber GetValidLinkInfo CompletePasswordRecovery DeleteExpiredPasswordRecovery); +use Koha::Patron::Password::Recovery qw( + CompletePasswordRecovery + DeleteExpiredPasswordRecovery + GetValidLinkInfo + SendPasswordRecoveryEmail + ValidateBorrowernumber +); use Koha::Patrons; my $query = CGI->new; -use HTML::Entities; -use Try::Tiny; -use List::Util qw/any/; +use HTML::Entities (); +use Try::Tiny qw( catch try ); +use List::Util qw( any ); my ( $template, $dummy, $cookie ) = get_template_and_user( { diff --git a/opac/opac-patron-consent.pl b/opac/opac-patron-consent.pl old mode 100755 new mode 100644 index 362c4b7aab7..017e04e9be2 --- a/opac/opac-patron-consent.pl +++ b/opac/opac-patron-consent.pl @@ -22,7 +22,7 @@ use CGI qw/-utf8/; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use Koha::DateUtils qw/dt_from_string/; +use Koha::DateUtils qw( dt_from_string ); use Koha::Patron::Consents; use Koha::Patrons; diff --git a/opac/opac-patron-image.pl b/opac/opac-patron-image.pl old mode 100755 new mode 100644 diff --git a/opac/opac-privacy.pl b/opac/opac-privacy.pl old mode 100755 new mode 100644 diff --git a/opac/opac-ratings-ajax.pl b/opac/opac-ratings-ajax.pl old mode 100755 new mode 100644 index 70dfcd62c17..37377bb1fae --- a/opac/opac-ratings-ajax.pl +++ b/opac/opac-ratings-ajax.pl @@ -30,12 +30,11 @@ use CGI::Cookie; # need to check cookies before having CGI parse the POST reque use C4::Auth qw( get_template_and_user check_cookie_auth ); use C4::Context; -use C4::Debug; use C4::Output qw( is_ajax output_ajax_with_http_headers ); use Koha::Ratings; -use JSON; +use JSON (); my $is_ajax = is_ajax(); diff --git a/opac/opac-ratings.pl b/opac/opac-ratings.pl old mode 100755 new mode 100644 index b6bf4eac36b..7e1bca61cb3 --- a/opac/opac-ratings.pl +++ b/opac/opac-ratings.pl @@ -30,7 +30,6 @@ use CGI qw ( -utf8 ); use C4::Auth qw( checkauth ); use C4::Context; -use C4::Debug; use Koha::Ratings; diff --git a/opac/opac-readingrecord.pl b/opac/opac-readingrecord.pl old mode 100755 new mode 100644 index d385f07e36d..c7dea49ae38 --- a/opac/opac-readingrecord.pl +++ b/opac/opac-readingrecord.pl @@ -21,13 +21,16 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Koha qw( GetNormalizedISBN getitemtypeimagelocation GetNormalizedUPC ); -use C4::Biblio qw( GetXmlBiblio ); +use C4::Koha qw( + getitemtypeimagelocation + GetNormalizedISBN + GetNormalizedUPC +); +use C4::Biblio (); use C4::Circulation; use C4::Members qw( GetAllIssues ); use C4::External::BakerTaylor qw( image_url link_url ); -use Koha::DateUtils; -use MARC::Record; +use MARC::Record (); use C4::Output qw( output_html_with_http_headers ); use C4::Charset qw( StripNonXmlChars ); diff --git a/opac/opac-recordedbooks-search.pl b/opac/opac-recordedbooks-search.pl old mode 100755 new mode 100644 diff --git a/opac/opac-registration-verify.pl b/opac/opac-registration-verify.pl old mode 100755 new mode 100644 index 7574f7fa79d..d6d9babb5a0 --- a/opac/opac-registration-verify.pl +++ b/opac/opac-registration-verify.pl @@ -23,7 +23,7 @@ use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Members; use C4::Form::MessagingPreferences; -use Koha::AuthUtils qw( generate_password ); +use Koha::AuthUtils (); use Koha::Patrons; use Koha::Patron::Consent; use Koha::Patron::Modifications; diff --git a/opac/opac-renew.pl b/opac/opac-renew.pl old mode 100755 new mode 100644 index 12c14c9449a..95bc34c6ddd --- a/opac/opac-renew.pl +++ b/opac/opac-renew.pl @@ -27,11 +27,9 @@ use CGI qw ( -utf8 ); use C4::Circulation qw( CanBookBeRenewed AddRenewal ); use C4::Auth qw( get_template_and_user ); use C4::Context; -use C4::Items; use C4::Members; use Koha::Items; use Koha::Patrons; -use Date::Calc qw( Today Date_to_Days ); my $query = CGI->new; my ( $template, $borrowernumber, $cookie ) = get_template_and_user( diff --git a/opac/opac-reportproblem.pl b/opac/opac-reportproblem.pl old mode 100755 new mode 100644 index 9b03c135fee..fa5ba8cd2cf --- a/opac/opac-reportproblem.pl +++ b/opac/opac-reportproblem.pl @@ -19,17 +19,17 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Try::Tiny; +use Try::Tiny qw( catch try ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Letters qw( GetPreparedLetter EnqueueLetter ); +use C4::Letters (); use Koha::ProblemReport; use Koha::Libraries; use Koha::Patrons; use Koha::Util::Navigation; -use URI::Escape; -use Encode; +use URI::Escape qw( uri_unescape ); +use Encode (); my $input = CGI->new; diff --git a/opac/opac-request-article.pl b/opac/opac-request-article.pl old mode 100755 new mode 100644 diff --git a/opac/opac-reserve.pl b/opac/opac-reserve.pl old mode 100755 new mode 100644 index 4fb06bd434f..b5e2d3dd27d --- a/opac/opac-reserve.pl +++ b/opac/opac-reserve.pl @@ -22,28 +22,26 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Koha qw( getitemtypeimagesrc getitemtypeimagelocation ); +use C4::Koha qw( getitemtypeimagelocation getitemtypeimagesrc ); use C4::Circulation qw( GetBranchItemRule GetTransfers ); use C4::Reserves qw( CanItemBeReserved CanBookBeReserved AddReserve GetReservesControlBranch IsAvailableForItemLevelRequest ); -use C4::Biblio qw( GetBiblioData GetMarcBiblio GetFrameworkCode ); -use C4::Items qw( GetItemsInfo GetHostItemsInfo sub ); +use C4::Biblio qw( GetBiblioData GetFrameworkCode GetMarcBiblio ); +use C4::Items qw( GetHostItemsInfo GetItemsInfo ); use C4::Output qw( output_html_with_http_headers ); use C4::Context; use C4::Members; use C4::Overdues; -use C4::Debug; use Koha::AuthorisedValues; use Koha::Biblios; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::CirculationRules; use Koha::Items; use Koha::ItemTypes; use Koha::Checkouts; use Koha::Libraries; use Koha::Patrons; -use Date::Calc qw/Today Date_to_Days/; -use List::MoreUtils qw/uniq/; +use List::MoreUtils qw( uniq ); my $maxreserves = C4::Context->preference("maxreserves"); diff --git a/opac/opac-restrictedpage.pl b/opac/opac-restrictedpage.pl old mode 100755 new mode 100644 index 3270f99e8e6..36505d009eb --- a/opac/opac-restrictedpage.pl +++ b/opac/opac-restrictedpage.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/opac/opac-retrieve-file.pl b/opac/opac-retrieve-file.pl old mode 100755 new mode 100644 index 3f6e6c8d3be..8385f82fedd --- a/opac/opac-retrieve-file.pl +++ b/opac/opac-retrieve-file.pl @@ -18,8 +18,7 @@ # along with Koha; if not, see . use Modern::Perl; -use CGI; -use Encode; +use Encode (); use C4::Auth qw( get_template_and_user ); use C4::Context; diff --git a/opac/opac-review.pl b/opac/opac-review.pl old mode 100755 new mode 100644 index 6f3763ca1ea..32757496ed5 --- a/opac/opac-review.pl +++ b/opac/opac-review.pl @@ -20,14 +20,12 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Output qw( output_html_with_http_headers ); -use C4::Biblio; use C4::Scrubber; -use C4::Debug; +use C4::Debug qw( $cgi_debug ); use Koha::Biblios; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::Review; use Koha::Reviews; diff --git a/opac/opac-routing-lists.pl b/opac/opac-routing-lists.pl old mode 100755 new mode 100644 diff --git a/opac/opac-search-history.pl b/opac/opac-search-history.pl old mode 100755 new mode 100644 index d36ef99d76b..5c732104e6f --- a/opac/opac-search-history.pl +++ b/opac/opac-search-history.pl @@ -23,13 +23,8 @@ use C4::Auth qw( get_template_and_user ); use CGI qw ( -utf8 ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::Log; -use C4::Items; -use C4::Debug; use C4::Search::History; -use URI::Escape; -use POSIX qw(strftime); my $cgi = CGI->new; diff --git a/opac/opac-search.pl b/opac/opac-search.pl old mode 100755 new mode 100644 index 225419bbe83..8466c571b73 --- a/opac/opac-search.pl +++ b/opac/opac-search.pl @@ -28,11 +28,9 @@ use Modern::Perl; # to perform, etc. ## load Koha modules use C4::Context; -use List::MoreUtils q/any/; -use Try::Tiny; -use Encode; +use List::MoreUtils qw( any ); +use Encode (); -use Data::Dumper; # TODO remove use Koha::SearchEngine::Search; use Koha::SearchEngine::QueryBuilder; @@ -45,14 +43,13 @@ $searcher = Koha::SearchEngine::Search->new({index => 'biblios'}); use C4::Output qw( output_html_with_http_headers pagination_bar output_with_http_headers ); use C4::Auth qw( get_template_and_user get_session ); -use C4::Languages qw( getlanguage getLanguages ); +use C4::Languages qw( getLanguages ); use C4::Search qw( searchResults ); use C4::Search qw( searchResults ); -use C4::Biblio qw( GetXmlBiblio CountItemsIssued ); +use C4::Biblio qw( CountItemsIssued ); use C4::Koha qw( GetItemTypesCategorized getitemtypeimagelocation GetAuthorisedValues ); -use C4::Tags qw( get_tags get_tag ); +use C4::Tags qw( get_tags ); use C4::SocialData; -use C4::External::OverDrive; use C4::External::BakerTaylor qw( image_url link_url ); use Koha::CirculationRules; @@ -65,10 +62,9 @@ use Koha::Patrons; use Koha::Plugins; use Koha::SearchFields; -use POSIX qw(ceil floor strftime); -use URI::Escape; -use JSON qw/decode_json encode_json/; -use Business::ISBN; +use POSIX qw( strftime ); +use URI::Escape qw( uri_escape_utf8 uri_unescape ); +use Business::ISBN (); my $DisplayMultiPlaceHold = C4::Context->preference("DisplayMultiPlaceHold"); # create a new CGI object diff --git a/opac/opac-sendbasket.pl b/opac/opac-sendbasket.pl old mode 100755 new mode 100644 index 8fdfa96f610..c5a2c7e571f --- a/opac/opac-sendbasket.pl +++ b/opac/opac-sendbasket.pl @@ -20,12 +20,17 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Encode qw(encode); -use Carp; -use Try::Tiny; - -use C4::Biblio qw( GetBiblioData GetMarcBiblio GetMarcAuthors GetMarcSubjects ); -use C4::Items qw( sub GetItemsInfo ); +use Encode (); +use Carp qw( carp ); +use Try::Tiny qw( catch try ); + +use C4::Biblio qw( + GetBiblioData + GetMarcAuthors + GetMarcBiblio + GetMarcSubjects +); +use C4::Items qw( GetItemsInfo ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Members; diff --git a/opac/opac-sendshelf.pl b/opac/opac-sendshelf.pl old mode 100755 new mode 100644 index 58b68420fac..42a34dcefb3 --- a/opac/opac-sendshelf.pl +++ b/opac/opac-sendshelf.pl @@ -20,13 +20,20 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Encode qw( encode ); -use Carp; -use Try::Tiny; +use Encode (); +use Carp qw( carp ); +use Try::Tiny qw( catch try ); use C4::Auth qw( get_template_and_user ); -use C4::Biblio qw( GetMarcBiblio GetFrameworkCode GetBiblioData GetMarcAuthors GetMarcSubjects GetMarcISBN ); -use C4::Items qw( sub GetItemsInfo ); +use C4::Biblio qw( + GetBiblioData + GetFrameworkCode + GetMarcAuthors + GetMarcBiblio + GetMarcISBN + GetMarcSubjects +); +use C4::Items qw( GetItemsInfo ); use C4::Output qw( output_html_with_http_headers ); use C4::Members; use Koha::Email; diff --git a/opac/opac-serial-issues.pl b/opac/opac-serial-issues.pl old mode 100755 new mode 100644 index 3167ba91a23..ac35fb3b552 --- a/opac/opac-serial-issues.pl +++ b/opac/opac-serial-issues.pl @@ -22,9 +22,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Serials qw( GetFullSubscription GetFullSubscriptionsFromBiblionumber PrepareSerialsData GetSubscription GetSubscriptionsFromBiblionumber ); -use C4::Letters; use C4::Output qw( output_html_with_http_headers ); use C4::Context; diff --git a/opac/opac-shareshelf.pl b/opac/opac-shareshelf.pl old mode 100755 new mode 100644 index bff02910efc..6143e052bb9 --- a/opac/opac-shareshelf.pl +++ b/opac/opac-shareshelf.pl @@ -29,8 +29,7 @@ use Email::Valid; use C4::Auth qw( get_template_and_user ); use C4::Context; -use C4::Letters qw( GetPreparedLetter EnqueueLetter ); -use C4::Members (); +use C4::Letters (); use C4::Output qw( output_html_with_http_headers ); use Koha::Patrons; diff --git a/opac/opac-shelves.pl b/opac/opac-shelves.pl old mode 100755 new mode 100644 index d19efb9e79b..57ce044dc8f --- a/opac/opac-shelves.pl +++ b/opac/opac-shelves.pl @@ -21,13 +21,18 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Biblio qw( GetBiblioData GetMarcBiblio GetFrameworkCode ); +use C4::Biblio qw( GetBiblioData GetFrameworkCode GetMarcBiblio ); use C4::External::BakerTaylor qw( image_url link_url ); -use C4::Koha qw( getitemtypeimagelocation GetNormalizedUPC GetNormalizedEAN GetNormalizedOCLCNumber GetNormalizedISBN ); +use C4::Koha qw( + GetNormalizedEAN + GetNormalizedISBN + GetNormalizedOCLCNumber + GetNormalizedUPC +); use C4::Items qw( GetItemsLocationInfo ); use C4::Members; use C4::Output qw( pagination_bar output_with_http_headers ); -use C4::Tags qw( get_tags get_tag ); +use C4::Tags qw( get_tags ); use C4::XSLT; use Koha::Biblios; diff --git a/opac/opac-showmarc.pl b/opac/opac-showmarc.pl old mode 100755 new mode 100644 index 69074dc392d..eed2bae30f9 --- a/opac/opac-showmarc.pl +++ b/opac/opac-showmarc.pl @@ -21,13 +21,12 @@ use Modern::Perl; # standard or CPAN modules used use CGI qw ( -utf8 ); -use Encode; +use Encode (); # Koha modules used use C4::Context; use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Biblio; use C4::ImportBatch; use C4::XSLT (); use C4::Templates; diff --git a/opac/opac-showreviews.pl b/opac/opac-showreviews.pl old mode 100755 new mode 100644 index cc25c27247b..e0ce553cf8d --- a/opac/opac-showreviews.pl +++ b/opac/opac-showreviews.pl @@ -22,14 +22,19 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Koha qw( GetNormalizedUPC GetNormalizedEAN GetNormalizedOCLCNumber GetNormalizedISBN ); +use C4::Koha qw( + GetNormalizedEAN + GetNormalizedISBN + GetNormalizedOCLCNumber + GetNormalizedUPC +); use C4::Output qw( output_html_with_http_headers ); use C4::Circulation; use C4::Biblio qw( GetMarcBiblio ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::Patrons; use Koha::Reviews; -use POSIX qw(ceil floor strftime); +use POSIX qw( ceil floor ); my $template_name; my $query = CGI->new; diff --git a/opac/opac-suggestions.pl b/opac/opac-suggestions.pl old mode 100755 new mode 100644 index ada516cf252..429eccfb022 --- a/opac/opac-suggestions.pl +++ b/opac/opac-suggestions.pl @@ -19,7 +19,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Encode qw( encode ); +use Encode (); use C4::Auth qw( get_template_and_user ); use C4::Members; use C4::Koha qw( GetAuthorisedValues ); @@ -33,7 +33,7 @@ use Koha::AuthorisedValues; use Koha::Libraries; use Koha::Patrons; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); my $input = CGI->new; my $op = $input->param('op') || 'else'; diff --git a/opac/opac-tags.pl b/opac/opac-tags.pl old mode 100755 new mode 100644 index ed8cf5f2e72..36feca56de3 --- a/opac/opac-tags.pl +++ b/opac/opac-tags.pl @@ -37,15 +37,21 @@ use CGI::Cookie; # need to check cookies before having CGI parse the POST reques use C4::Auth qw( check_cookie_auth get_template_and_user ); use C4::Context; -use C4::Debug; +use C4::Debug qw( $debug ); use C4::Output qw( output_with_http_headers is_ajax output_html_with_http_headers ); use C4::Scrubber; use C4::Biblio qw( GetMarcBiblio ); -use C4::Items qw( sub GetItemsInfo GetHiddenItemnumbers ); -use C4::Tags qw( add_tag remove_tag get_tag_rows get_tag get_approval_rows stratify_tags ); +use C4::Items qw( GetHiddenItemnumbers GetItemsInfo ); +use C4::Tags qw( + add_tag + get_approval_rows + get_tag_rows + remove_tag + stratify_tags +); use C4::XSLT; -use Data::Dumper; +use Data::Dumper qw( Dumper ); use Koha::Biblios; use Koha::CirculationRules; diff --git a/opac/opac-tags_subject.pl b/opac/opac-tags_subject.pl old mode 100755 new mode 100644 index 9cc4d1af579..05403a189f8 --- a/opac/opac-tags_subject.pl +++ b/opac/opac-tags_subject.pl @@ -30,7 +30,6 @@ use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use CGI qw ( -utf8 ); -use C4::Biblio; my $query = CGI->new; diff --git a/opac/opac-topissues.pl b/opac/opac-topissues.pl old mode 100755 new mode 100644 index 4c0b2e934f1..bb2d58a9938 --- a/opac/opac-topissues.pl +++ b/opac/opac-topissues.pl @@ -24,12 +24,9 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Context; -use C4::Languages; use C4::Search; use C4::Output qw( output_html_with_http_headers ); -use C4::Koha; use C4::Circulation qw( GetTopIssues ); -use Date::Manip; =head1 NAME diff --git a/opac/opac-user.pl b/opac/opac-user.pl old mode 100755 new mode 100644 index 421012a32b9..816b400eebc --- a/opac/opac-user.pl +++ b/opac/opac-user.pl @@ -22,19 +22,21 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Koha qw( getitemtypeimagelocation GetNormalizedISBN GetNormalizedUPC ); +use C4::Koha qw( + getitemtypeimagelocation + GetNormalizedISBN + GetNormalizedUPC +); use C4::Circulation qw( CanBookBeRenewed GetRenewCount GetIssuingCharges GetSoonestRenewDate ); use C4::External::BakerTaylor qw( image_url link_url ); use C4::Reserves qw( GetReserveStatus ); use C4::Members; use C4::Output qw( output_html_with_http_headers ); use C4::Biblio qw( GetMarcBiblio ); -use C4::Items; -use C4::Letters; use Koha::Account::Lines; use Koha::Biblios; use Koha::Libraries; -use Koha::DateUtils; +use Koha::DateUtils qw( output_pref ); use Koha::Holds; use Koha::Database; use Koha::ItemTypes; @@ -48,12 +50,8 @@ use Koha::Token; use constant ATTRIBUTE_SHOW_BARCODE => 'SHOW_BCODE'; -use Scalar::Util qw(looks_like_number); -use Date::Calc qw( - Today - Add_Delta_Days - Date_to_Days -); +use Scalar::Util qw( looks_like_number ); +use Date::Calc qw( Date_to_Days Today ); my $query = CGI->new; diff --git a/opac/sci/sci-main.pl b/opac/sci/sci-main.pl old mode 100755 new mode 100644 index aeafc7ff236..2171fa42c51 --- a/opac/sci/sci-main.pl +++ b/opac/sci/sci-main.pl @@ -25,7 +25,7 @@ use C4::Output qw( output_html_with_http_headers ); use Koha::Items; use List::MoreUtils qw( uniq ); -use Try::Tiny; +use Try::Tiny qw( catch try ); my $cgi = CGI->new; diff --git a/opac/sco/help.pl b/opac/sco/help.pl old mode 100755 new mode 100644 diff --git a/opac/sco/printslip.pl b/opac/sco/printslip.pl old mode 100755 new mode 100644 index e130202a8bf..a2564f1307f --- a/opac/sco/printslip.pl +++ b/opac/sco/printslip.pl @@ -32,7 +32,6 @@ use C4::Context; use C4::Auth qw( in_iprange get_session get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Members qw( IssueSlip ); -use C4::Koha; my $input = CGI->new; unless ( in_iprange(C4::Context->preference('SelfCheckAllowByIPRanges')) ) { diff --git a/opac/sco/sco-main.pl b/opac/sco/sco-main.pl old mode 100755 new mode 100644 index 015dcf9012c..93a63e1bd1d --- a/opac/sco/sco-main.pl +++ b/opac/sco/sco-main.pl @@ -36,13 +36,10 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( in_iprange get_template_and_user checkpw ); -use C4::Koha; use C4::Circulation qw( AddReturn CanBookBeIssued AddIssue CanBookBeRenewed AddRenewal ); use C4::Reserves; use C4::Output qw( output_html_with_http_headers ); use C4::Members; -use C4::Biblio; -use C4::Items; use Koha::DateUtils qw( dt_from_string ); use Koha::Acquisition::Currencies; use Koha::Items; diff --git a/opac/sco/sco-patron-image.pl b/opac/sco/sco-patron-image.pl old mode 100755 new mode 100644 diff --git a/opac/svc/shelfbrowser.pl b/opac/svc/shelfbrowser.pl old mode 100755 new mode 100644 diff --git a/opac/tracklinks.pl b/opac/tracklinks.pl old mode 100755 new mode 100644 index f854ca87bb1..c3439c090b7 --- a/opac/tracklinks.pl +++ b/opac/tracklinks.pl @@ -21,12 +21,12 @@ use Modern::Perl; use C4::Context; use C4::Auth qw( checkauth ); -use C4::Biblio qw( GetMarcBiblio GetMarcUrls ); +use C4::Biblio (); use C4::Output qw( output_error ); use Koha::Items; use Koha::Linktracker; use CGI qw ( -utf8 ); -use List::MoreUtils qw(any); +use List::MoreUtils qw( any ); my $cgi = CGI->new; my $uri = $cgi->param('uri') || ''; diff --git a/patron_lists/add-modify.pl b/patron_lists/add-modify.pl old mode 100755 new mode 100644 index 3d5f92bce9c..95ff7287073 --- a/patron_lists/add-modify.pl +++ b/patron_lists/add-modify.pl @@ -23,7 +23,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use Koha::List::Patron; +use Koha::List::Patron qw( AddPatronList GetPatronLists ModPatronList ); my $cgi = CGI->new; diff --git a/patron_lists/delete.pl b/patron_lists/delete.pl old mode 100755 new mode 100644 index 948f92aed8c..773ec3d1686 --- a/patron_lists/delete.pl +++ b/patron_lists/delete.pl @@ -23,7 +23,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output; -use Koha::List::Patron; +use Koha::List::Patron qw( DelPatronList ); my $cgi = CGI->new; diff --git a/patron_lists/list.pl b/patron_lists/list.pl old mode 100755 new mode 100644 index 3796355dba1..7076b20c9f3 --- a/patron_lists/list.pl +++ b/patron_lists/list.pl @@ -23,8 +23,12 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use Koha::List::Patron; -use List::MoreUtils qw/uniq/; +use Koha::List::Patron qw( + AddPatronsToList + DelPatronsFromList + GetPatronLists +); +use List::MoreUtils qw( uniq ); my $cgi = CGI->new; diff --git a/patron_lists/lists.pl b/patron_lists/lists.pl old mode 100755 new mode 100644 index aa8b878a6fd..f599cd164b9 --- a/patron_lists/lists.pl +++ b/patron_lists/lists.pl @@ -23,7 +23,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use Koha::List::Patron; +use Koha::List::Patron qw( GetPatronLists ); my $cgi = CGI->new; diff --git a/patron_lists/patrons.pl b/patron_lists/patrons.pl old mode 100755 new mode 100644 index 145c24e3def..f97fcf46622 --- a/patron_lists/patrons.pl +++ b/patron_lists/patrons.pl @@ -23,7 +23,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use Koha::List::Patron; +use Koha::List::Patron qw( AddPatronList GetPatronLists ModPatronList ); my $cgi = CGI->new; diff --git a/patroncards/add_user_search.pl b/patroncards/add_user_search.pl old mode 100755 new mode 100644 diff --git a/patroncards/create-pdf.pl b/patroncards/create-pdf.pl old mode 100755 new mode 100644 index bde50b96798..7d4d0593af0 --- a/patroncards/create-pdf.pl +++ b/patroncards/create-pdf.pl @@ -20,17 +20,16 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use Graphics::Magick; -use XML::Simple; -use POSIX qw(ceil); -use Storable qw(dclone); +use Graphics::Magick (); +use XML::Simple qw( XMLin ); +use POSIX qw( ceil ); +use Storable qw( dclone ); use autouse 'Data::Dumper' => qw(Dumper); -use C4::Debug; use C4::Context; -use C4::Creators; -use C4::Patroncards; -use Koha::List::Patron; +use C4::Creators (); +use C4::Patroncards (); +use Koha::List::Patron qw( GetPatronLists ); use Koha::Patrons; use Koha::Patron::Images; diff --git a/patroncards/edit-batch.pl b/patroncards/edit-batch.pl old mode 100755 new mode 100644 index c7d57fd0b30..693a6f3cdc8 --- a/patroncards/edit-batch.pl +++ b/patroncards/edit-batch.pl @@ -27,8 +27,8 @@ use autouse 'Data::Dumper' => qw(Dumper); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Creators; -use C4::Patroncards; +use C4::Creators qw( get_card_summary html_table ); +use C4::Patroncards (); use Koha::Patrons; my $cgi = CGI->new; diff --git a/patroncards/edit-layout.pl b/patroncards/edit-layout.pl old mode 100755 new mode 100644 index 301550ed1a0..aac4fce9ef0 --- a/patroncards/edit-layout.pl +++ b/patroncards/edit-layout.pl @@ -21,14 +21,19 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Text::CSV_XS; -use XML::Simple; +use XML::Simple qw( XMLin XMLout ); use autouse 'Data::Dumper' => qw(Dumper); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Creators; -use C4::Patroncards; +use C4::Creators qw( + get_all_image_names + get_barcode_types + get_font_types + get_text_justification_types + get_unit_values +); +use C4::Patroncards (); my $cgi = CGI->new; my ( $template, $loggedinuser, $cookie ) = get_template_and_user( diff --git a/patroncards/edit-profile.pl b/patroncards/edit-profile.pl old mode 100755 new mode 100644 index dced7fc47d1..c302035749d --- a/patroncards/edit-profile.pl +++ b/patroncards/edit-profile.pl @@ -24,7 +24,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Creators::Lib qw(get_all_templates get_unit_values); +use C4::Creators::Lib qw( get_all_templates get_unit_values ); use C4::Patroncards::Profile; my $cgi = CGI->new; diff --git a/patroncards/edit-template.pl b/patroncards/edit-template.pl old mode 100755 new mode 100644 index 163e772fb76..bc8bb246131 --- a/patroncards/edit-template.pl +++ b/patroncards/edit-template.pl @@ -25,8 +25,8 @@ use autouse 'Data::Dumper' => qw(Dumper); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Creators; -use C4::Patroncards; +use C4::Creators qw( get_all_profiles get_unit_values ); +use C4::Patroncards (); my $cgi = CGI->new; my ( $template, $loggedinuser, $cookie ) = get_template_and_user( diff --git a/patroncards/home.pl b/patroncards/home.pl old mode 100755 new mode 100644 diff --git a/patroncards/image-manage.pl b/patroncards/image-manage.pl old mode 100755 new mode 100644 index 75fcef254f1..a120156ec8c --- a/patroncards/image-manage.pl +++ b/patroncards/image-manage.pl @@ -3,15 +3,13 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Graphics::Magick; -use POSIX qw(ceil); +use Graphics::Magick (); use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Debug; -use C4::Creators; -use C4::Patroncards; +use C4::Creators qw( html_table ); +use C4::Patroncards qw( get_image put_image rm_image ); my $cgi = CGI->new; diff --git a/patroncards/manage.pl b/patroncards/manage.pl old mode 100755 new mode 100644 index 1333926789b..06377de5ae1 --- a/patroncards/manage.pl +++ b/patroncards/manage.pl @@ -26,10 +26,16 @@ use autouse 'Data::Dumper' => qw(Dumper); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Creators; -use C4::Patroncards; +use C4::Creators qw( + get_all_layouts + get_all_profiles + get_all_templates + get_batch_summary + html_table +); +use C4::Patroncards (); use C4::Labels; -use Koha::List::Patron; +use Koha::List::Patron qw( GetPatronLists ); my $cgi = CGI->new; my ( $template, $loggedinuser, $cookie ) = get_template_and_user( diff --git a/patroncards/print.pl b/patroncards/print.pl old mode 100755 new mode 100644 index 6bafdadeef0..cacb9cdab8c --- a/patroncards/print.pl +++ b/patroncards/print.pl @@ -24,8 +24,7 @@ use autouse 'Data::Dumper' => qw(Dumper); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Creators; -use C4::Patroncards; +use C4::Creators qw( get_all_layouts get_all_templates get_output_formats ); my $cgi = CGI->new; my ( $template, $loggedinuser, $cookie ) = get_template_and_user( diff --git a/plugins/plugins-enable.pl b/plugins/plugins-enable.pl old mode 100755 new mode 100644 diff --git a/plugins/plugins-home.pl b/plugins/plugins-home.pl old mode 100755 new mode 100644 index 433bb238759..84e620215da --- a/plugins/plugins-home.pl +++ b/plugins/plugins-home.pl @@ -21,13 +21,12 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use JSON qw(from_json); -use LWP::Simple qw(get); +use JSON qw( from_json ); +use LWP::Simple qw( get ); use Koha::Plugins; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Debug; use C4::Context; my $plugins_enabled = C4::Context->config("enable_plugins"); diff --git a/plugins/plugins-uninstall.pl b/plugins/plugins-uninstall.pl old mode 100755 new mode 100644 index ab1d402a8fa..889ac7f94aa --- a/plugins/plugins-uninstall.pl +++ b/plugins/plugins-uninstall.pl @@ -18,15 +18,12 @@ use Modern::Perl; use Archive::Extract; -use File::Temp; -use File::Copy; use CGI qw ( -utf8 ); use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output; use C4::Members; -use C4::Debug; use Koha::Plugins::Handler; die("Koha plugins are disabled!") unless C4::Context->config("enable_plugins"); diff --git a/plugins/plugins-upload.pl b/plugins/plugins-upload.pl old mode 100755 new mode 100644 index 3bb8751d0dc..640f670b45a --- a/plugins/plugins-upload.pl +++ b/plugins/plugins-upload.pl @@ -21,14 +21,13 @@ use Modern::Perl; use Archive::Extract; use CGI qw ( -utf8 ); use Mojo::UserAgent; -use File::Copy; -use File::Temp; +use File::Temp (); use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Members; -use C4::Debug; +use C4::Debug qw( $debug ); use Koha::Plugins; my $plugins_enabled = C4::Context->config("enable_plugins"); diff --git a/plugins/run.pl b/plugins/run.pl old mode 100755 new mode 100644 index 3e07f5f11f8..4cfd88bdffc --- a/plugins/run.pl +++ b/plugins/run.pl @@ -24,7 +24,6 @@ use CGI qw ( -utf8 ); use Koha::Plugins::Handler; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Debug; use C4::Context; my $plugins_enabled = C4::Context->config("enable_plugins"); diff --git a/pos/pay.pl b/pos/pay.pl old mode 100755 new mode 100644 index b401f124958..32bbdd2338f --- a/pos/pay.pl +++ b/pos/pay.pl @@ -19,7 +19,7 @@ use Modern::Perl; -use CGI; +use CGI (); use JSON qw( from_json ); use C4::Auth qw( get_session get_template_and_user ); diff --git a/pos/printreceipt.pl b/pos/printreceipt.pl old mode 100755 new mode 100644 index 5e0f7f78958..516459974f2 --- a/pos/printreceipt.pl +++ b/pos/printreceipt.pl @@ -22,9 +22,8 @@ use Modern::Perl; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit_if_error output_and_exit output_html_with_http_headers ); use CGI qw ( -utf8 ); -use C4::Letters qw( getletter ); +use C4::Letters (); use Koha::Account::Lines; -use Koha::DateUtils; my $input = CGI->new; diff --git a/pos/register.pl b/pos/register.pl old mode 100755 new mode 100644 index a4275caa889..0f17c0dce43 --- a/pos/register.pl +++ b/pos/register.pl @@ -18,7 +18,7 @@ # along with Koha; if not, see . use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Context; @@ -26,7 +26,7 @@ use C4::Context; use Koha::Account::Lines; use Koha::Cash::Registers; use Koha::Database; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); my $input = CGI->new(); diff --git a/pos/registers.pl b/pos/registers.pl old mode 100755 new mode 100644 index 7a9c3a16996..7d5d2c88266 --- a/pos/registers.pl +++ b/pos/registers.pl @@ -18,7 +18,7 @@ # along with Koha; if not, see . use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Context; diff --git a/reports/acquisitions_stats.pl b/reports/acquisitions_stats.pl old mode 100755 new mode 100644 index 6e46298ad78..cce70b6faed --- a/reports/acquisitions_stats.pl +++ b/reports/acquisitions_stats.pl @@ -26,9 +26,9 @@ use C4::Reports qw( GetDelimiterChoices ); use C4::Output qw( output_html_with_http_headers ); use C4::Koha qw( GetAuthorisedValues ); use C4::Circulation; -use C4::Biblio qw( GetMarcSubfieldStructure GetMarcSubfieldStructureFromKohaField ); +use C4::Biblio qw( GetMarcSubfieldStructureFromKohaField ); use Koha::ItemTypes; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Libraries; =head1 NAME diff --git a/reports/bor_issues_top.pl b/reports/bor_issues_top.pl old mode 100755 new mode 100644 index adbead8709a..80e00b60786 --- a/reports/bor_issues_top.pl +++ b/reports/bor_issues_top.pl @@ -23,13 +23,12 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Context; -use C4::Koha; use C4::Circulation; use C4::Members; use C4::Reports qw( GetDelimiterChoices ); -use C4::Debug; +use C4::Debug qw( $debug ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::ItemTypes; use Koha::Patron::Categories; @@ -297,7 +296,7 @@ sub calculate { $patrons{$id}->{oldcols}->{$col} = $rank; } - use Data::Dumper; + use Data::Dumper qw( Dumper ); $strcalc =~ s/old_issues/issues/g; $debug and print $debugfh "(issues) SQL : $strcalc\n"; diff --git a/reports/borrowers_out.pl b/reports/borrowers_out.pl old mode 100755 new mode 100644 index 703da3ddb7d..9fa00001d74 --- a/reports/borrowers_out.pl +++ b/reports/borrowers_out.pl @@ -22,13 +22,12 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Context; -use C4::Koha; use C4::Output qw( output_html_with_http_headers ); use C4::Circulation; use C4::Reports qw( GetDelimiterChoices ); use C4::Members; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Patron::Categories; =head1 NAME diff --git a/reports/borrowers_stats.pl b/reports/borrowers_stats.pl old mode 100755 new mode 100644 index 25dd3f000bd..19d9c42223a --- a/reports/borrowers_stats.pl +++ b/reports/borrowers_stats.pl @@ -19,7 +19,6 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use List::MoreUtils qw/uniq/; use C4::Auth qw( get_template_and_user ); use C4::Context; @@ -30,15 +29,12 @@ use C4::Reports qw( GetDelimiterChoices ); use C4::Circulation; use Koha::AuthorisedValues; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Libraries; use Koha::Patron::Attribute::Types; use Koha::Patron::Categories; -use Date::Calc qw( - Today - Add_Delta_YM - ); +use Date::Calc qw( Add_Delta_YM Today ); =head1 NAME diff --git a/reports/cash_register_stats.pl b/reports/cash_register_stats.pl old mode 100755 new mode 100644 index a2e7cd80bd0..cb6ec0231e3 --- a/reports/cash_register_stats.pl +++ b/reports/cash_register_stats.pl @@ -17,16 +17,15 @@ use Modern::Perl; use C4::Auth qw( get_template_and_user ); -use CGI; +use CGI (); use C4::Context; use C4::Reports qw( GetDelimiterChoices ); use C4::Output qw( output_html_with_http_headers ); -use C4::Koha; use C4::Circulation; use DateTime; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Text::CSV::Encoded; -use List::Util qw/any/; +use List::Util qw( any ); use Koha::Account::CreditTypes; use Koha::Account::DebitTypes; diff --git a/reports/cat_issues_top.pl b/reports/cat_issues_top.pl old mode 100755 new mode 100644 index d52012e4ae3..36c397e2def --- a/reports/cat_issues_top.pl +++ b/reports/cat_issues_top.pl @@ -27,7 +27,7 @@ use C4::Koha qw( GetAuthorisedValues ); use C4::Circulation; use C4::Reports qw( GetDelimiterChoices ); use C4::Members; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::ItemTypes; =head1 NAME diff --git a/reports/catalogue_out.pl b/reports/catalogue_out.pl old mode 100755 new mode 100644 index bb721005597..104144b3d62 --- a/reports/catalogue_out.pl +++ b/reports/catalogue_out.pl @@ -22,10 +22,10 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Context; -use C4::Debug; +use C4::Debug qw( $debug ); use C4::Output qw( output_html_with_http_headers ); # use Date::Manip; # TODO: add not borrowed since date X criteria -use Data::Dumper; +use Data::Dumper qw( Dumper ); =head1 catalogue_out diff --git a/reports/catalogue_stats.pl b/reports/catalogue_stats.pl old mode 100755 new mode 100644 index d6ca4b63b63..364362954d4 --- a/reports/catalogue_stats.pl +++ b/reports/catalogue_stats.pl @@ -26,10 +26,10 @@ use C4::Output qw( output_html_with_http_headers ); use C4::Koha qw( GetAuthorisedValues ); use C4::Reports qw( GetDelimiterChoices ); use C4::Circulation; -use C4::Biblio qw( GetMarcSubfieldStructure GetMarcSubfieldStructureFromKohaField ); +use C4::Biblio qw( GetMarcSubfieldStructureFromKohaField ); use Koha::AuthorisedValues; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::ItemTypes; =head1 NAME diff --git a/reports/dictionary.pl b/reports/dictionary.pl old mode 100755 new mode 100644 index 93f4294effe..9a6af469830 --- a/reports/dictionary.pl +++ b/reports/dictionary.pl @@ -16,13 +16,12 @@ # # You should have received a copy of the GNU General Public License # along with Koha; if not, see . -use CGI::Carp qw(fatalsToBrowser warningsToBrowser); use Modern::Perl; use C4::Auth qw( get_template_and_user ); use CGI qw ( -utf8 ); use C4::Output qw( output_html_with_http_headers ); use C4::Reports::Guided qw( get_from_dictionary get_columns get_column_type get_distinct_values save_dictionary delete_definition get_report_areas ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); =head1 NAME diff --git a/reports/guided_reports.pl b/reports/guided_reports.pl old mode 100755 new mode 100644 index 46c0d8591fe..22b31b55eaa --- a/reports/guided_reports.pl +++ b/reports/guided_reports.pl @@ -21,24 +21,23 @@ use Modern::Perl; use CGI qw/-utf8/; use Text::CSV::Encoded; use Encode qw( decode ); -use URI::Escape; -use File::Temp; +use URI::Escape (); +use File::Temp (); use C4::Reports::Guided qw( delete_report get_report_areas convert_sql update_sql get_saved_reports get_results ValidateSQLParameters format_results get_report_types get_columns get_from_dictionary get_criteria build_query save_report execute_query nb_rows get_report_groups ); use Koha::Reports; use C4::Auth qw( get_template_and_user get_session ); use C4::Output qw( pagination_bar output_html_with_http_headers ); -use C4::Debug; use C4::Context; use Koha::Caches; -use C4::Log; -use Koha::DateUtils qw/dt_from_string output_pref/; +use C4::Log qw( logaction ); +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::AuthorisedValue; use Koha::AuthorisedValues; use Koha::BiblioFrameworks; use Koha::Libraries; use Koha::Patron::Categories; use Koha::SharedContent; -use Koha::Util::OpenDocument; +use Koha::Util::OpenDocument qw( generate_ods ); =head1 NAME diff --git a/reports/issues_avg_stats.pl b/reports/issues_avg_stats.pl old mode 100755 new mode 100644 index b95b72e4bc6..ad5a89bc8e8 --- a/reports/issues_avg_stats.pl +++ b/reports/issues_avg_stats.pl @@ -23,13 +23,12 @@ use C4::Auth qw( get_template_and_user ); use CGI qw ( -utf8 ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::Koha; use C4::Circulation; use C4::Reports qw( GetDelimiterChoices ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::ItemTypes; use Koha::Patron::Categories; -use Date::Calc qw(Delta_Days); +use Date::Calc qw( Delta_Days ); =head1 NAME diff --git a/reports/issues_stats.pl b/reports/issues_stats.pl old mode 100755 new mode 100644 index da9a6e730b2..647850c4fd3 --- a/reports/issues_stats.pl +++ b/reports/issues_stats.pl @@ -20,10 +20,9 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Date::Manip; use C4::Auth qw( get_template_and_user ); -use C4::Debug; +use C4::Debug qw( $debug ); use C4::Context; use C4::Koha qw( GetAuthorisedValues ); use C4::Output qw( output_html_with_http_headers ); @@ -32,7 +31,7 @@ use C4::Reports qw( GetDelimiterChoices ); use C4::Members; use Koha::AuthorisedValues; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::ItemTypes; use Koha::Patron::Attribute::Types; diff --git a/reports/itemslost.pl b/reports/itemslost.pl old mode 100755 new mode 100644 index d15abaec025..fec8a1bd187 --- a/reports/itemslost.pl +++ b/reports/itemslost.pl @@ -28,15 +28,12 @@ This script displays lost items. use Modern::Perl; use CGI qw ( -utf8 ); -use Text::CSV_XS; +use Text::CSV_XS (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Biblio; -use C4::Items; use Koha::AuthorisedValues; use Koha::CsvProfiles; -use Koha::DateUtils; my $query = CGI->new; my ( $template, $loggedinuser, $cookie ) = get_template_and_user( diff --git a/reports/manager.pl b/reports/manager.pl old mode 100755 new mode 100644 diff --git a/reports/orders_by_fund.pl b/reports/orders_by_fund.pl old mode 100755 new mode 100644 index ceb53b7d46d..49c408e23bd --- a/reports/orders_by_fund.pl +++ b/reports/orders_by_fund.pl @@ -31,11 +31,9 @@ use CGI qw( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Budgets; -use C4::Biblio; -use C4::Reports; use C4::Acquisition; #GetBasket() use Koha::Biblios; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); my $query = CGI->new; my ( $template, $loggedinuser, $cookie ) = get_template_and_user( diff --git a/reports/reports-home.pl b/reports/reports-home.pl old mode 100755 new mode 100644 diff --git a/reports/reserves_stats.pl b/reports/reserves_stats.pl old mode 100755 new mode 100644 index 022eabfa30c..e56788a7fe1 --- a/reports/reserves_stats.pl +++ b/reports/reserves_stats.pl @@ -22,18 +22,18 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Debug; +use C4::Debug qw( $debug ); use C4::Context; use C4::Koha qw( GetAuthorisedValues ); use C4::Output qw( output_html_with_http_headers ); use C4::Reports qw( GetDelimiterChoices ); use C4::Members; use Koha::AuthorisedValues; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::ItemTypes; use Koha::Libraries; use Koha::Patron::Categories; -use List::MoreUtils qw/any/; +use List::MoreUtils qw( any ); =head1 NAME diff --git a/reports/serials_stats.pl b/reports/serials_stats.pl old mode 100755 new mode 100644 index 77dda2998c3..27006a0f3bd --- a/reports/serials_stats.pl +++ b/reports/serials_stats.pl @@ -22,7 +22,6 @@ use C4::Auth qw( get_template_and_user ); use CGI qw ( -utf8 ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::Koha; use C4::Reports qw( GetDelimiterChoices ); use C4::Serials qw( GetExpirationDate HasSubscriptionExpired ); diff --git a/reserve/modrequest.pl b/reserve/modrequest.pl old mode 100755 new mode 100644 diff --git a/reserve/modrequest_suspendall.pl b/reserve/modrequest_suspendall.pl old mode 100755 new mode 100644 diff --git a/reserve/placerequest.pl b/reserve/placerequest.pl old mode 100755 new mode 100644 index d310e4ea0df..9b4f1909d7c --- a/reserve/placerequest.pl +++ b/reserve/placerequest.pl @@ -24,12 +24,9 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use C4::Biblio; -use C4::Items; use C4::Output; use C4::Reserves qw( CanItemBeReserved AddReserve CanBookBeReserved ); use C4::Circulation; -use C4::Members; use C4::Auth qw( checkauth ); use Koha::Items; diff --git a/reserve/request.pl b/reserve/request.pl old mode 100755 new mode 100644 index fe745f6d614..2eee5afc1db --- a/reserve/request.pl +++ b/reserve/request.pl @@ -29,23 +29,21 @@ script to place reserves/requests use Modern::Perl; use CGI qw ( -utf8 ); -use List::MoreUtils qw/uniq/; -use Date::Calc qw/Date_to_Days/; +use List::MoreUtils qw( uniq ); +use Date::Calc qw( Date_to_Days ); use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); use C4::Reserves qw( RevertWaitingStatus AlterPriority ToggleLowestPriority ToggleSuspend CanBookBeReserved GetMaxPatronHoldsForRecord ItemsAnyAvailableAndNotRestricted GetReservesControlBranch CanItemBeReserved IsAvailableForItemLevelRequest ); -use C4::Biblio; -use C4::Items qw( get_hostitemnumbers_of sub ); +use C4::Items qw( get_hostitemnumbers_of ); use C4::Koha qw( getitemtypeimagelocation ); use C4::Serials qw( CountSubscriptionFromBiblionumber ); use C4::Circulation qw( GetTransfers _GetCircControlBranch GetBranchItemRule ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use C4::Utils::DataTables::Members; -use C4::Members; use C4::Search qw( enabled_staff_search_views ); use Koha::Biblios; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Checkouts; use Koha::Holds; use Koha::CirculationRules; diff --git a/reviews/reviewswaiting.pl b/reviews/reviewswaiting.pl old mode 100755 new mode 100644 index fcaf638c9b4..f97efa7daa1 --- a/reviews/reviewswaiting.pl +++ b/reviews/reviewswaiting.pl @@ -21,7 +21,6 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( pagination_bar output_html_with_http_headers ); use C4::Context; -use C4::Biblio; use Koha::Biblios; use Koha::Patrons; use Koha::Reviews; diff --git a/rotating_collections/addItems.pl b/rotating_collections/addItems.pl old mode 100755 new mode 100644 index 3dc21534751..f3c3a246086 --- a/rotating_collections/addItems.pl +++ b/rotating_collections/addItems.pl @@ -22,7 +22,6 @@ use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::RotatingCollections; -use C4::Items; use Koha::Items; diff --git a/rotating_collections/editCollections.pl b/rotating_collections/editCollections.pl old mode 100755 new mode 100644 diff --git a/rotating_collections/rotatingCollections.pl b/rotating_collections/rotatingCollections.pl old mode 100755 new mode 100644 diff --git a/rotating_collections/transferCollection.pl b/rotating_collections/transferCollection.pl old mode 100755 new mode 100644 diff --git a/serials/acqui-search-result.pl b/serials/acqui-search-result.pl old mode 100755 new mode 100644 index ebcd9da1965..989259b3355 --- a/serials/acqui-search-result.pl +++ b/serials/acqui-search-result.pl @@ -42,11 +42,10 @@ acqui-search-result.pl use Modern::Perl; use C4::Auth qw( get_template_and_user ); -use C4::Biblio; use C4::Output qw( output_html_with_http_headers ); use CGI qw ( -utf8 ); use C4::Acquisition qw( SearchOrders ); -use Koha::DateUtils; +use Koha::DateUtils qw( output_pref ); use Koha::Acquisition::Booksellers; diff --git a/serials/acqui-search.pl b/serials/acqui-search.pl old mode 100755 new mode 100644 diff --git a/serials/add_user_search.pl b/serials/add_user_search.pl old mode 100755 new mode 100644 diff --git a/serials/checkexpiration.pl b/serials/checkexpiration.pl old mode 100755 new mode 100644 index 6bb46a531b3..bc0ad74f59a --- a/serials/checkexpiration.pl +++ b/serials/checkexpiration.pl @@ -48,7 +48,7 @@ use C4::Auth qw( get_template_and_user ); use C4::Serials qw( SearchSubscriptions GetExpirationDate ); use C4::Output qw( output_html_with_http_headers ); use C4::Context; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use DateTime; diff --git a/serials/claims.pl b/serials/claims.pl old mode 100755 new mode 100644 index b1eb1b50cc4..81aef06b042 --- a/serials/claims.pl +++ b/serials/claims.pl @@ -24,8 +24,7 @@ use C4::Serials qw( GetSuppliersWithLateIssues GetLateOrMissingIssues updateClai use C4::Acquisition; use C4::Output qw( output_html_with_http_headers ); use C4::Context; -use C4::Letters qw( SendAlerts GetLetters ); -use C4::Koha qw( GetAuthorisedValues ); +use C4::Letters qw( GetLetters SendAlerts ); use Koha::AdditionalFields; use Koha::CsvProfiles; diff --git a/serials/create-numberpattern.pl b/serials/create-numberpattern.pl old mode 100755 new mode 100644 index 110daf5f004..de6f04d997d --- a/serials/create-numberpattern.pl +++ b/serials/create-numberpattern.pl @@ -20,9 +20,11 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Context; -use C4::Serials::Numberpattern; +use C4::Serials::Numberpattern qw( + AddSubscriptionNumberpattern + ModSubscriptionNumberpattern +); use C4::Auth qw( check_cookie_auth ); -use URI::Escape; my $input = CGI->new; diff --git a/serials/lateissues-export.pl b/serials/lateissues-export.pl old mode 100755 new mode 100644 index f6e0ab56e77..f981bc12c71 --- a/serials/lateissues-export.pl +++ b/serials/lateissues-export.pl @@ -25,7 +25,7 @@ use C4::Context; use Koha::CsvProfiles; -use Text::CSV_XS; +use Text::CSV_XS (); my $query = CGI->new; my $supplierid = $query->param('supplierid'); diff --git a/serials/reorder_members.pl b/serials/reorder_members.pl old mode 100755 new mode 100644 diff --git a/serials/routing-preview.pl b/serials/routing-preview.pl old mode 100755 new mode 100644 index 61d7b068295..246e3d74019 --- a/serials/routing-preview.pl +++ b/serials/routing-preview.pl @@ -27,11 +27,9 @@ use C4::Acquisition; use C4::Reserves qw( AddReserve ModReserve ); use C4::Circulation; use C4::Context; -use C4::Members; -use C4::Biblio; -use C4::Items qw( sub GetItemsInfo ); +use C4::Items qw( GetItemsInfo ); use C4::Serials qw( delroutingmember getroutinglist GetSubscription GetSerials check_routing ); -use URI::Escape; +use URI::Escape (); use Koha::Biblios; use Koha::Libraries; diff --git a/serials/routing.pl b/serials/routing.pl old mode 100755 new mode 100644 index 0e888150cea..a5895638973 --- a/serials/routing.pl +++ b/serials/routing.pl @@ -34,11 +34,10 @@ use C4::Acquisition; use C4::Output qw( output_and_exit output_html_with_http_headers ); use C4::Context; -use C4::Members; use C4::Serials qw( GetSubscription delroutingmember addroutingmember getroutinglist GetSerials GetLatestSerials check_routing ); use Koha::Patrons; -use URI::Escape; +use URI::Escape (); my $query = CGI->new; my $subscriptionid = $query->param('subscriptionid'); diff --git a/serials/serials-collection.pl b/serials/serials-collection.pl old mode 100755 new mode 100644 index 7c7d3013e22..d482e2ea05d --- a/serials/serials-collection.pl +++ b/serials/serials-collection.pl @@ -22,16 +22,14 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Serials qw( ModSerialStatus GetSubscription GetNextExpected GetNextSeq GetNextDate NewIssue HasSubscriptionExpired abouttoexpire check_routing GetFullSubscription PrepareSerialsData CountSubscriptionFromBiblionumber GetSubscriptionsFromBiblionumber GetFullSubscriptionsFromBiblionumber ); -use C4::Letters; use C4::Output qw( output_and_exit output_html_with_http_headers ); use C4::Context; use Koha::Serial::Items; use Koha::DateUtils qw( dt_from_string ); -use List::MoreUtils qw/uniq/; +use List::MoreUtils qw( uniq ); my $query = CGI->new; diff --git a/serials/serials-edit.pl b/serials/serials-edit.pl old mode 100755 new mode 100644 index 2bff4da87f1..bc7c809551f --- a/serials/serials-edit.pl +++ b/serials/serials-edit.pl @@ -63,21 +63,20 @@ op can be : use Modern::Perl; use CGI qw ( -utf8 ); -use Encode qw( decode is_utf8 ); +use Encode (); use C4::Auth qw( get_template_and_user haspermission ); -use C4::Biblio qw( TransformHtmlToXml GetMarcFromKohaField ); -use C4::Items qw( sub PrepareItemrecordDisplay AddItemFromMarc ModItemFromMarc ); -use C4::Koha; +use C4::Biblio qw( GetMarcFromKohaField TransformHtmlToXml ); +use C4::Items qw( AddItemFromMarc ModItemFromMarc PrepareItemrecordDisplay ); use C4::Output qw( output_html_with_http_headers ); use C4::Context; use C4::Serials qw( GetSerials GetSerials2 GetSerialInformation HasSubscriptionExpired GetSubscription abouttoexpire NewIssue ModSerialStatus GetPreviousSerialid AddItem2Serial ); use C4::Search qw( enabled_staff_search_views ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Items; use Koha::Serial::Items; -use List::MoreUtils qw/uniq/; +use List::MoreUtils qw( uniq ); my $query = CGI->new(); my $dbh = C4::Context->dbh; diff --git a/serials/serials-home.pl b/serials/serials-home.pl old mode 100755 new mode 100644 diff --git a/serials/serials-search.pl b/serials/serials-search.pl old mode 100755 new mode 100644 index 6b86fc59e18..c5ace74097c --- a/serials/serials-search.pl +++ b/serials/serials-search.pl @@ -32,12 +32,11 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Context; -use C4::Koha qw( GetAuthorisedValues ); use C4::Output qw( output_html_with_http_headers ); use C4::Serials qw( CloseSubscription ReopenSubscription SearchSubscriptions check_routing ); use Koha::AdditionalFields; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::SharedContent; my $query = CGI->new; diff --git a/serials/showpredictionpattern.pl b/serials/showpredictionpattern.pl old mode 100755 new mode 100644 index 3ea342a0c32..77bac6dc58e --- a/serials/showpredictionpattern.pl +++ b/serials/showpredictionpattern.pl @@ -31,12 +31,12 @@ publication date, based on frequency and first publication date. use Modern::Perl; use CGI qw ( -utf8 ); -use Date::Calc qw(Today Day_of_Year Week_of_Year Day_of_Week Days_in_Year Delta_Days Add_Delta_Days Add_Delta_YM); +use Date::Calc qw( Add_Delta_Days Add_Delta_YM Day_of_Week Delta_Days ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Serials qw( GetSubscription GetFictiveIssueNumber GetSeq GetSubscriptionIrregularities GetNextDate GetNextSeq ); use C4::Serials qw( GetSubscription GetFictiveIssueNumber GetSeq GetSubscriptionIrregularities GetNextDate GetNextSeq ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); my $input = CGI->new; my ($template, $loggedinuser, $cookie, $flags) = get_template_and_user( { diff --git a/serials/subscription-add.pl b/serials/subscription-add.pl old mode 100755 new mode 100644 index ac4191a53d4..bf6e7971b0a --- a/serials/subscription-add.pl +++ b/serials/subscription-add.pl @@ -18,7 +18,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Date::Calc qw(Today Day_of_Year Week_of_Year Add_Delta_Days Add_Delta_YM); +use Date::Calc qw( Add_Delta_Days Add_Delta_YM ); use C4::Koha qw( GetAuthorisedValues ); use C4::Biblio qw( GetMarcBiblio ); use C4::Auth qw( get_template_and_user ); @@ -31,9 +31,9 @@ use C4::Serials qw( GetSubscription GetNextExpected GetSerials GetSubscriptionLe use C4::Letters qw( GetLetters ); use Koha::AdditionalFields; use Koha::Biblios; -use Koha::DateUtils; +use Koha::DateUtils qw( output_pref ); use Koha::ItemTypes; -use Carp; +use Carp qw( carp ); use Koha::Subscription::Numberpattern; use Koha::Subscription::Frequency; diff --git a/serials/subscription-batchedit.pl b/serials/subscription-batchedit.pl old mode 100755 new mode 100644 index e8134f80370..4e069b9ab66 --- a/serials/subscription-batchedit.pl +++ b/serials/subscription-batchedit.pl @@ -27,7 +27,7 @@ use C4::Serials qw( can_edit_subscription ); use Koha::Subscriptions; use Koha::Acquisition::Booksellers; use Koha::AdditionalFields; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); my $cgi = CGI->new; diff --git a/serials/subscription-bib-search.pl b/serials/subscription-bib-search.pl old mode 100755 new mode 100644 index aba405e3378..ba2568f3440 --- a/serials/subscription-bib-search.pl +++ b/serials/subscription-bib-search.pl @@ -55,7 +55,7 @@ use C4::Context; use C4::Output qw( output_html_with_http_headers ); use C4::Search qw( new_record_from_zebra ); use C4::Biblio qw( TransformMarcToKoha ); -use C4::Debug; +use C4::Debug qw( $debug ); use Koha::ItemTypes; use Koha::SearchEngine; diff --git a/serials/subscription-detail.pl b/serials/subscription-detail.pl old mode 100755 new mode 100644 index 67ceb5ada34..3f6e0af4d43 --- a/serials/subscription-detail.pl +++ b/serials/subscription-detail.pl @@ -20,7 +20,6 @@ use CGI qw ( -utf8 ); use C4::Acquisition; use C4::Auth qw( get_template_and_user checkauth ); use C4::Budgets; -use C4::Koha; use C4::Serials qw( CloseSubscription ReopenSubscription GetSubscription GetExpirationDate GetSerials HasSubscriptionStrictlyExpired CountIssues HasItems DelSubscription check_routing abouttoexpire can_edit_subscription ); use C4::Output qw( output_and_exit output_html_with_http_headers ); use C4::Context; @@ -28,12 +27,11 @@ use C4::Search qw( enabled_staff_search_views ); use Koha::AdditionalFields; use Koha::AuthorisedValues; -use Koha::DateUtils; +use Koha::DateUtils qw( output_pref ); use Koha::Acquisition::Bookseller; use Koha::Subscriptions; -use Date::Calc qw/Today Day_of_Year Week_of_Year Add_Delta_Days/; -use Carp; +use Carp qw( carp ); use Koha::SharedContent; diff --git a/serials/subscription-frequencies.pl b/serials/subscription-frequencies.pl old mode 100755 new mode 100644 diff --git a/serials/subscription-frequency.pl b/serials/subscription-frequency.pl old mode 100755 new mode 100644 index 2915f323b67..4d46a83d794 --- a/serials/subscription-frequency.pl +++ b/serials/subscription-frequency.pl @@ -20,7 +20,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Context; -use C4::Serials::Frequency; +use C4::Serials::Frequency qw( GetSubscriptionFrequency ); use C4::Auth qw( check_cookie_auth ); use JSON qw( to_json ); diff --git a/serials/subscription-history.pl b/serials/subscription-history.pl old mode 100755 new mode 100644 index 4e324147d74..c4d7ea713c5 --- a/serials/subscription-history.pl +++ b/serials/subscription-history.pl @@ -33,10 +33,9 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Biblio; use C4::Serials qw( ModSubscriptionHistory ModSubscription GetSubscriptionHistoryFromSubscriptionId GetSubscription ); use Koha::Biblios; -use Koha::DateUtils; +use Koha::DateUtils qw( output_pref ); my $input = CGI->new; my ($template, $loggedinuser, $cookie, $flags) = get_template_and_user( { diff --git a/serials/subscription-numberpattern.pl b/serials/subscription-numberpattern.pl old mode 100755 new mode 100644 index 47a7273db62..cc6b2926f7f --- a/serials/subscription-numberpattern.pl +++ b/serials/subscription-numberpattern.pl @@ -19,7 +19,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use C4::Serials::Numberpattern; +use C4::Serials::Numberpattern qw( GetSubscriptionNumberpattern ); use C4::Auth qw( check_cookie_auth ); use JSON qw( to_json ); diff --git a/serials/subscription-numberpatterns.pl b/serials/subscription-numberpatterns.pl old mode 100755 new mode 100644 index 6dba137b07e..19b917bb05e --- a/serials/subscription-numberpatterns.pl +++ b/serials/subscription-numberpatterns.pl @@ -32,8 +32,16 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Serials::Numberpattern; -use C4::Serials::Frequency; +use C4::Serials::Numberpattern qw( + AddSubscriptionNumberpattern + DelSubscriptionNumberpattern + GetSubscriptionNumberpattern + GetSubscriptionNumberpatternByName + GetSubscriptionNumberpatterns + GetSubscriptionsWithNumberpattern + ModSubscriptionNumberpattern +); +use C4::Serials::Frequency qw( GetSubscriptionFrequencies ); my $input = CGI->new; my ($template, $loggedinuser, $cookie, $flags) = get_template_and_user( { diff --git a/serials/subscription-renew.pl b/serials/subscription-renew.pl old mode 100755 new mode 100644 index d614fc14e27..1983b05fb12 --- a/serials/subscription-renew.pl +++ b/serials/subscription-renew.pl @@ -46,14 +46,14 @@ Id of the subscription this script has to renew use Modern::Perl; use CGI qw ( -utf8 ); -use Carp; +use Carp qw( carp ); use C4::Koha; use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit output_html_with_http_headers ); use C4::Serials qw( GetSubscription GetSubscriptionLength NewSubscription ReNewSubscription ); -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); my $query = CGI->new; my $dbh = C4::Context->dbh; diff --git a/serials/viewalerts.pl b/serials/viewalerts.pl old mode 100755 new mode 100644 diff --git a/services/itemrecorddisplay.pl b/services/itemrecorddisplay.pl old mode 100755 new mode 100644 diff --git a/suggestion/add_user_search.pl b/suggestion/add_user_search.pl old mode 100755 new mode 100644 diff --git a/suggestion/suggestion.pl b/suggestion/suggestion.pl old mode 100755 new mode 100644 index 58cc53dfc64..92d02805a85 --- a/suggestion/suggestion.pl +++ b/suggestion/suggestion.pl @@ -27,14 +27,13 @@ use C4::Koha qw( GetAuthorisedValues ); use C4::Budgets; use C4::Search qw( FindDuplicate GetDistinctValues ); use C4::Members; -use C4::Debug; use Koha::DateUtils qw( dt_from_string ); use Koha::AuthorisedValues; use Koha::Acquisition::Currencies; use Koha::Libraries; use Koha::Patrons; -use URI::Escape; +use URI::Escape qw( uri_escape ); sub Init{ my $suggestion= shift @_; diff --git a/svc/cataloguing/automatic_linker.pl b/svc/cataloguing/automatic_linker.pl old mode 100755 new mode 100644 index 05f3821a27c..7728a49b1f1 --- a/svc/cataloguing/automatic_linker.pl +++ b/svc/cataloguing/automatic_linker.pl @@ -18,10 +18,10 @@ # along with Koha; if not, see . use Modern::Perl; -use CGI; -use JSON; +use CGI (); +use JSON qw( to_json ); use C4::Auth qw( check_cookie_auth ); -use C4::Biblio qw( TransformHtmlToMarc BiblioAutoLink ); +use C4::Biblio qw( BiblioAutoLink TransformHtmlToMarc ); use C4::Context; my $input = CGI->new; diff --git a/t/Koha/sleep.pl b/t/Koha/sleep.pl old mode 100755 new mode 100644 index 009b4034dcf..e8d80d8e0d1 --- a/t/Koha/sleep.pl +++ b/t/Koha/sleep.pl @@ -4,7 +4,6 @@ use Modern::Perl; use Koha::Script; use Fcntl qw(:flock); -use Try::Tiny; # # Lock execution my $script = Koha::Script->new({ script => 'sleep.pl' }); diff --git a/t/Koha/wait.pl b/t/Koha/wait.pl old mode 100755 new mode 100644 index f909cb1f066..afa2b2bf471 --- a/t/Koha/wait.pl +++ b/t/Koha/wait.pl @@ -4,7 +4,6 @@ use Modern::Perl; use Koha::Script; use Fcntl qw(:flock); -use Try::Tiny; # # Lock execution my $script = Koha::Script->new({ script => 'sleep.pl' }); diff --git a/t/db_dependent/LDAP/test_ldap_add.pl b/t/db_dependent/LDAP/test_ldap_add.pl old mode 100755 new mode 100644 diff --git a/t/db_dependent/zebra_config.pl b/t/db_dependent/zebra_config.pl old mode 100755 new mode 100644 index 8dde14cf329..b0e7a4635bb --- a/t/db_dependent/zebra_config.pl +++ b/t/db_dependent/zebra_config.pl @@ -2,11 +2,11 @@ use Modern::Perl; -use File::Copy; -use File::Path qw(make_path); -use File::Find; -use File::Basename; -use File::Spec; +use File::Copy qw( copy ); +use File::Path qw( make_path ); +use File::Find qw( find ); +use File::Basename qw( dirname ); +use File::Spec (); use C4::Context; diff --git a/t/etc/schema.pl b/t/etc/schema.pl old mode 100755 new mode 100644 diff --git a/tags/list.pl b/tags/list.pl old mode 100755 new mode 100644 index 3ffcbe638d6..2e17f5815fb --- a/tags/list.pl +++ b/tags/list.pl @@ -24,8 +24,7 @@ use C4::Auth qw( get_template_and_user ); use C4::Biblio qw( GetBiblioData ); use C4::Context; use C4::Items qw( GetItemsInfo ); -use C4::Koha; -use C4::Tags qw( remove_tag get_tag_rows get_tag get_tags ); +use C4::Tags qw( get_tag_rows get_tags remove_tag ); use C4::Output qw( output_html_with_http_headers ); my $needed_flags = { tools => 'moderate_tags' diff --git a/tags/review.pl b/tags/review.pl old mode 100755 new mode 100644 index b292d6995dc..68abef03353 --- a/tags/review.pl +++ b/tags/review.pl @@ -20,18 +20,24 @@ # along with Koha; if not, see . use Modern::Perl; -use Data::Dumper; -use POSIX; +use Data::Dumper qw( Dumper ); +use POSIX qw( ceil exit ); use CGI qw ( -utf8 ); use CGI::Cookie; # need to check cookies before having CGI parse the POST request -use URI::Escape; +use URI::Escape qw( uri_escape_utf8 ); use C4::Auth qw( check_cookie_auth get_template_and_user ); use C4::Context; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); # use C4::Koha; use C4::Output qw( output_with_http_headers is_ajax pagination_bar output_html_with_http_headers ); -use C4::Debug; -use C4::Tags qw( is_approved whitelist blacklist approval_counts get_approval_rows ); +use C4::Debug qw( $debug ); +use C4::Tags qw( + approval_counts + blacklist + get_approval_rows + is_approved + whitelist +); my $script_name = "/cgi-bin/koha/tags/review.pl"; my $needed_flags = { tools => 'moderate_tags' }; # FIXME: replace when more specific permission is created. diff --git a/tools/access_files.pl b/tools/access_files.pl old mode 100755 new mode 100644 index 7961517a45b..63d68977918 --- a/tools/access_files.pl +++ b/tools/access_files.pl @@ -24,13 +24,12 @@ use Modern::Perl; use C4::Auth qw( get_template_and_user ); -use CGI; +use CGI (); use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::Koha; -use File::stat qw(stat); -use Digest::MD5 qw(md5_hex); -use Encode; +use File::stat qw( stat ); +use Digest::MD5 qw( md5_hex ); +use Encode qw( decode ); my $input = CGI->new; my $file_id = $input->param("id"); diff --git a/tools/ajax-inventory.pl b/tools/ajax-inventory.pl old mode 100755 new mode 100644 diff --git a/tools/automatic_item_modification_by_age.pl b/tools/automatic_item_modification_by_age.pl old mode 100755 new mode 100644 index c8a0d5a3713..996b3c90684 --- a/tools/automatic_item_modification_by_age.pl +++ b/tools/automatic_item_modification_by_age.pl @@ -31,12 +31,11 @@ This script allows a user to update the new status for items. use Modern::Perl; -use CGI; -use JSON qw( to_json from_json ); +use CGI (); +use JSON qw( to_json ); use C4::Auth qw( get_template_and_user ); use C4::Context; -use C4::Items qw( sub ); use C4::Output qw( output_html_with_http_headers ); use C4::Koha; diff --git a/tools/background-job-progress.pl b/tools/background-job-progress.pl old mode 100755 new mode 100644 index 9e45292ebd9..e9e914d0d76 --- a/tools/background-job-progress.pl +++ b/tools/background-job-progress.pl @@ -20,7 +20,6 @@ use Modern::Perl; # standard or CPAN modules used -use IO::File; use CGI qw ( -utf8 ); use CGI::Session; use C4::Context; diff --git a/tools/batchMod.pl b/tools/batchMod.pl old mode 100755 new mode 100644 index f8f56d90e2a..dcd06a08da2 --- a/tools/batchMod.pl +++ b/tools/batchMod.pl @@ -20,27 +20,33 @@ use CGI qw ( -utf8 ); use Modern::Perl; -use Try::Tiny; +use Try::Tiny qw( catch try ); use C4::Auth qw( get_template_and_user haspermission ); use C4::Output qw( output_html_with_http_headers ); -use C4::Biblio qw( GetMarcStructure GetMarcFromKohaField TransformHtmlToXml DelBiblio IsMarcStructureInternal GetAuthorisedValueDesc ); -use C4::Items qw( sub Item2Marc ModItemFromMarc GetItemsInfo ); +use C4::Biblio qw( + DelBiblio + GetAuthorisedValueDesc + GetMarcFromKohaField + GetMarcStructure + IsMarcStructureInternal + TransformHtmlToXml +); +use C4::Items qw( GetItemsInfo Item2Marc ModItemFromMarc ); use C4::Circulation qw( LostItem IsItemIssued ); use C4::Context; use C4::Koha; use C4::BackgroundJob; -use C4::ClassSource qw( GetClassSources GetClassSource ); -use C4::Debug; +use C4::ClassSource qw( GetClassSources ); use C4::Members; use MARC::File::XML; -use List::MoreUtils qw/uniq/; +use List::MoreUtils qw( uniq ); use Koha::Database; use Koha::Exceptions::Exception; use Koha::AuthorisedValues; use Koha::Biblios; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::Items; use Koha::ItemTypes; use Koha::Patrons; diff --git a/tools/batch_delete_records.pl b/tools/batch_delete_records.pl old mode 100755 new mode 100644 index 268a08f46b2..8a3c4a6b6b9 --- a/tools/batch_delete_records.pl +++ b/tools/batch_delete_records.pl @@ -20,13 +20,13 @@ use Modern::Perl; -use CGI; +use CGI (); use List::MoreUtils qw( uniq ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Biblio qw( GetMarcBiblio CountItemsIssued DelBiblio ); +use C4::Biblio qw( GetMarcBiblio ); use Koha::Virtualshelves; use Koha::Authorities; diff --git a/tools/batch_extend_due_dates.pl b/tools/batch_extend_due_dates.pl old mode 100755 new mode 100644 index 77c80237abf..1ff2a50e8e1 --- a/tools/batch_extend_due_dates.pl +++ b/tools/batch_extend_due_dates.pl @@ -20,7 +20,7 @@ use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/tools/batch_record_modification.pl b/tools/batch_record_modification.pl old mode 100755 new mode 100644 index d101be38dba..a081758bbd8 --- a/tools/batch_record_modification.pl +++ b/tools/batch_record_modification.pl @@ -20,16 +20,17 @@ use Modern::Perl; -use CGI; +use CGI (); use List::MoreUtils qw( uniq ); -use JSON qw( encode_json ); -use Try::Tiny; +use Try::Tiny qw( catch try ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Biblio qw( GetMarcBiblio ModBiblio ); -use C4::MarcModificationTemplates qw( GetModificationTemplateActions GetModificationTemplates ); +use C4::MarcModificationTemplates qw( + GetModificationTemplateActions + GetModificationTemplates +); use Koha::Biblios; use Koha::BackgroundJob::BatchUpdateBiblio; diff --git a/tools/batch_records_ajax.pl b/tools/batch_records_ajax.pl old mode 100755 new mode 100644 index 9f47835c536..1085348da91 --- a/tools/batch_records_ajax.pl +++ b/tools/batch_records_ajax.pl @@ -32,10 +32,9 @@ the records from an import batch. use Modern::Perl; use CGI qw ( -utf8 ); -use JSON qw/ to_json /; +use JSON qw( to_json ); use C4::Context; -use C4::Charset; use C4::Auth qw( check_cookie_auth ); use C4::ImportBatch qw( GetImportBatch GetImportRecordsRange GetImportRecordMatches ); diff --git a/tools/cleanborrowers.pl b/tools/cleanborrowers.pl old mode 100755 new mode 100644 index f52ef54c753..1d4324dea3c --- a/tools/cleanborrowers.pl +++ b/tools/cleanborrowers.pl @@ -41,9 +41,8 @@ use C4::Circulation; # AnonymiseIssueHistory. use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::Patron::Categories; use Koha::Patrons; -use Date::Calc qw/Today Add_Delta_YM/; use Koha::Patrons; -use Koha::List::Patron; +use Koha::List::Patron qw( GetPatronLists ); my $cgi = CGI->new; diff --git a/tools/copy-holidays.pl b/tools/copy-holidays.pl old mode 100755 new mode 100644 diff --git a/tools/csv-profiles.pl b/tools/csv-profiles.pl old mode 100755 new mode 100644 index 3c9755ff01c..86212ee6e58 --- a/tools/csv-profiles.pl +++ b/tools/csv-profiles.pl @@ -35,13 +35,12 @@ This script allow the user to define a new profile for CSV export =cut use Modern::Perl; -use Encode; +use Encode (); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use CGI qw ( -utf8 ); -use C4::Koha; use Koha::CsvProfiles; my $input = CGI->new; diff --git a/tools/exceptionHolidays.pl b/tools/exceptionHolidays.pl old mode 100755 new mode 100644 index 6bd650c5a9e..a96b1d0ebb6 --- a/tools/exceptionHolidays.pl +++ b/tools/exceptionHolidays.pl @@ -9,7 +9,7 @@ use C4::Output; use DateTime; use C4::Calendar; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); my $input = CGI->new; my $dbh = C4::Context->dbh(); diff --git a/tools/export.pl b/tools/export.pl old mode 100755 new mode 100644 index 1a7b5dbc85a..08f6858b0ee --- a/tools/export.pl +++ b/tools/export.pl @@ -19,7 +19,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); use MARC::File::XML; -use List::MoreUtils qw(uniq); +use List::MoreUtils qw( uniq ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); @@ -27,7 +27,7 @@ use Koha::Authority::Types; use Koha::Biblioitems; use Koha::CsvProfiles; use Koha::Database; -use Koha::DateUtils qw( dt_from_string output_pref ); +use Koha::DateUtils qw( dt_from_string ); use Koha::Exporter::Record; use Koha::ItemTypes; use Koha::Libraries; diff --git a/tools/holidays.pl b/tools/holidays.pl old mode 100755 new mode 100644 index e8ca096c14f..f36b470d729 --- a/tools/holidays.pl +++ b/tools/holidays.pl @@ -24,7 +24,7 @@ use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); use C4::Calendar; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); my $input = CGI->new; diff --git a/tools/import_borrowers.pl b/tools/import_borrowers.pl old mode 100755 new mode 100644 index 0dd584fa226..0e6681afddb --- a/tools/import_borrowers.pl +++ b/tools/import_borrowers.pl @@ -40,14 +40,14 @@ use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit output_html_with_http_headers ); use C4::Templates; use Koha::Patrons; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::Token; use Koha::Libraries; use Koha::Patron::Categories; use Koha::Patron::Attribute::Types; -use Koha::List::Patron; +use Koha::List::Patron qw( AddPatronList AddPatronsToList ); -use Koha::Patrons::Import; +use Koha::Patrons::Import (); my $Import = Koha::Patrons::Import->new(); use Text::CSV; diff --git a/tools/inventory.pl b/tools/inventory.pl old mode 100755 new mode 100644 index 368ced987d4..3dfa528d2ed --- a/tools/inventory.pl +++ b/tools/inventory.pl @@ -29,15 +29,14 @@ my $barcodelist = $input->param('barcodelist'); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::Biblio; -use C4::Items qw( GetItemsForInventory sub ); +use C4::Items qw( GetItemsForInventory ); use C4::Koha qw( GetAuthorisedValues ); use C4::Circulation qw( AddReturn ); use C4::Reports::Guided qw( _get_column_defs ); use C4::Charset qw( NormalizeString ); use Koha::Biblios; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); use Koha::AuthorisedValues; use Koha::BiblioFrameworks; use Koha::ClassSources; diff --git a/tools/koha-news.pl b/tools/koha-news.pl old mode 100755 new mode 100644 index e1337813225..59946e74491 --- a/tools/koha-news.pl +++ b/tools/koha-news.pl @@ -25,13 +25,18 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::NewsChannels; +use C4::NewsChannels qw( + add_opac_new + del_opac_new + get_opac_new + get_opac_news + upd_opac_new +); use C4::Languages qw( getTranslatedLanguages ); -use Date::Calc qw/Date_to_Days Today/; -use Koha::DateUtils; +use Date::Calc qw( Date_to_Days Today ); +use Koha::DateUtils qw( dt_from_string output_pref ); my $cgi = CGI->new; diff --git a/tools/letter.pl b/tools/letter.pl old mode 100755 new mode 100644 index db35984b7bb..ca948ae977e --- a/tools/letter.pl +++ b/tools/letter.pl @@ -45,8 +45,8 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); -use C4::Letters qw( GetLetterTemplates GetMessageTransportTypes GetMessage getletter ); -use C4::Log; +use C4::Letters qw( GetMessageTransportTypes ); +use C4::Log qw( logaction ); use Koha::Patron::Attribute::Types; diff --git a/tools/manage-marc-import.pl b/tools/manage-marc-import.pl old mode 100755 new mode 100644 index ae8534ffef9..10df6505bb2 --- a/tools/manage-marc-import.pl +++ b/tools/manage-marc-import.pl @@ -30,7 +30,6 @@ use C4::Koha; use C4::Auth qw( get_template_and_user ); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Biblio; use C4::ImportBatch qw( CleanBatch DeleteBatch sub GetImportBatch GetImportBatchOverlayAction GetImportBatchNoMatchAction GetImportBatchItemAction SetImportBatchOverlayAction SetImportBatchNoMatchAction SetImportBatchItemAction BatchFindDuplicates SetImportBatchMatcher GetItemNumbersFromImportBatch GetImportBatchRangeDesc GetNumberOfNonZ3950ImportBatches BatchCommitRecords BatchRevertRecords ); use C4::Matcher; use C4::BackgroundJob; diff --git a/tools/marc_modification_templates.pl b/tools/marc_modification_templates.pl old mode 100755 new mode 100644 index 0a71dd7da2f..f2194957e09 --- a/tools/marc_modification_templates.pl +++ b/tools/marc_modification_templates.pl @@ -21,9 +21,17 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Output qw( output_html_with_http_headers ); -use C4::MarcModificationTemplates; +use C4::MarcModificationTemplates qw( + AddModificationTemplate + AddModificationTemplateAction + DelModificationTemplate + DelModificationTemplateAction + GetModificationTemplateActions + GetModificationTemplates + ModModificationTemplateAction + MoveModificationTemplateAction +); my $cgi = CGI->new; diff --git a/tools/modborrowers.pl b/tools/modborrowers.pl old mode 100755 new mode 100644 index c11c5663e5c..a12c81d715f --- a/tools/modborrowers.pl +++ b/tools/modborrowers.pl @@ -31,12 +31,11 @@ use C4::Auth qw( get_template_and_user ); use C4::Koha qw( GetAuthorisedValues ); use C4::Members; use C4::Output qw( output_html_with_http_headers ); -use List::MoreUtils qw /any uniq/; use Koha::DateUtils qw( dt_from_string ); -use Koha::List::Patron; +use Koha::List::Patron qw( GetPatronLists ); use Koha::Libraries; use Koha::Patron::Categories; -use Koha::Patron::Debarments; +use Koha::Patron::Debarments qw( AddDebarment DelDebarment GetDebarments ); use Koha::Patrons; my $input = CGI->new; diff --git a/tools/newHolidays.pl b/tools/newHolidays.pl old mode 100755 new mode 100644 index d82c9acda94..b07079d52b1 --- a/tools/newHolidays.pl +++ b/tools/newHolidays.pl @@ -26,7 +26,7 @@ use C4::Output; use C4::Calendar; use DateTime; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string output_pref ); my $input = CGI->new; my $dbh = C4::Context->dbh(); diff --git a/tools/overduerules.pl b/tools/overduerules.pl old mode 100755 new mode 100644 index 777914c6385..c7bbf83bbb8 --- a/tools/overduerules.pl +++ b/tools/overduerules.pl @@ -22,8 +22,7 @@ use CGI qw ( -utf8 ); use C4::Context; use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); -use C4::Koha; -use C4::Letters qw( GetLetters GetLettersAvailableForALibrary GetMessageTransportTypes GetMessage ); +use C4::Letters (); use C4::Members; use C4::Overdues qw( GetOverdueMessageTransportTypes ); use Koha::Libraries; diff --git a/tools/picture-upload.pl b/tools/picture-upload.pl old mode 100755 new mode 100644 index 39f9b35f95d..90586d29ee8 --- a/tools/picture-upload.pl +++ b/tools/picture-upload.pl @@ -21,15 +21,14 @@ use Modern::Perl; -use File::Temp; -use File::Copy; +use File::Temp (); use CGI qw ( -utf8 ); -use GD; +use GD (); use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_and_exit output_html_with_http_headers ); use C4::Members; -use C4::Debug; +use C4::Debug qw( $debug ); use Koha::Patrons; use Koha::Patron::Images; diff --git a/tools/problem-reports.pl b/tools/problem-reports.pl old mode 100755 new mode 100644 diff --git a/tools/quotes-upload.pl b/tools/quotes-upload.pl old mode 100755 new mode 100644 index 8ce8e7eb20b..34e3de829ca --- a/tools/quotes-upload.pl +++ b/tools/quotes-upload.pl @@ -23,7 +23,6 @@ use CGI qw ( -utf8 ); use autouse 'Data::Dumper' => qw(Dumper); use C4::Auth qw( get_template_and_user ); -use C4::Koha; use C4::Context; use C4::Output qw( output_html_with_http_headers ); diff --git a/tools/quotes.pl b/tools/quotes.pl old mode 100755 new mode 100644 index 88db8502644..50cef1e489c --- a/tools/quotes.pl +++ b/tools/quotes.pl @@ -18,7 +18,7 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Try::Tiny; +use Try::Tiny qw( catch try ); use C4::Auth qw( get_template_and_user ); use C4::Context; diff --git a/tools/scheduler.pl b/tools/scheduler.pl old mode 100755 new mode 100644 index 63524ac2a7c..e4f27e1257b --- a/tools/scheduler.pl +++ b/tools/scheduler.pl @@ -19,12 +19,12 @@ use Modern::Perl; use C4::Context; -use C4::Scheduler qw( add_at_job remove_at_job get_jobs ); +use C4::Scheduler qw( add_at_job get_jobs remove_at_job ); use C4::Reports::Guided qw( get_saved_reports ); use C4::Auth qw( get_template_and_user ); use CGI qw ( -utf8 ); use C4::Output qw( output_html_with_http_headers ); -use Koha::DateUtils;; +use Koha::DateUtils qw( dt_from_string output_pref );; use vars qw($debug); diff --git a/tools/showdiffmarc.pl b/tools/showdiffmarc.pl old mode 100755 new mode 100644 diff --git a/tools/stage-marc-import.pl b/tools/stage-marc-import.pl old mode 100755 new mode 100644 index d9d20b96adc..b22c149d05a --- a/tools/stage-marc-import.pl +++ b/tools/stage-marc-import.pl @@ -35,12 +35,11 @@ use MARC::File::USMARC; use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); -use C4::Biblio; use C4::ImportBatch qw( RecordsFromMARCXMLFile RecordsFromISO2709File RecordsFromMarcPlugin BatchStageMarcRecords BatchFindDuplicates SetImportBatchMatcher SetImportBatchOverlayAction SetImportBatchNoMatchAction SetImportBatchItemAction sub ); use C4::Matcher; use Koha::UploadedFiles; use C4::BackgroundJob; -use C4::MarcModificationTemplates; +use C4::MarcModificationTemplates qw( GetModificationTemplates ); use Koha::Plugins; use Koha::ImportBatches; diff --git a/tools/stockrotation.pl b/tools/stockrotation.pl old mode 100755 new mode 100644 index b1d25484561..8d06afbe8aa --- a/tools/stockrotation.pl +++ b/tools/stockrotation.pl @@ -25,7 +25,7 @@ =cut use Modern::Perl; -use CGI; +use CGI (); use C4::Auth qw( get_template_and_user ); use C4::Context; diff --git a/tools/tools-home.pl b/tools/tools-home.pl old mode 100755 new mode 100644 diff --git a/tools/upload-cover-image.pl b/tools/upload-cover-image.pl old mode 100755 new mode 100644 index f9cbc6fde06..93f8cea81f6 --- a/tools/upload-cover-image.pl +++ b/tools/upload-cover-image.pl @@ -39,9 +39,9 @@ resized, maintaining aspect ratio. use Modern::Perl; -use File::Temp; +use File::Temp (); use CGI qw ( -utf8 ); -use GD; +use GD (); use C4::Context; use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); @@ -49,7 +49,7 @@ use Koha::Biblios; use Koha::CoverImages; use Koha::Items; use Koha::UploadedFiles; -use C4::Log; +use C4::Log qw( logaction ); my $debug = 1; diff --git a/tools/upload-file.pl b/tools/upload-file.pl old mode 100755 new mode 100644 index bef77ab260a..0725968c02f --- a/tools/upload-file.pl +++ b/tools/upload-file.pl @@ -21,9 +21,9 @@ use Modern::Perl; use CGI qw ( -utf8 ); use CGI::Cookie; -use Encode; -use JSON; -use URI::Escape; +use Encode (); +use JSON (); +use URI::Escape qw( uri_unescape ); use C4::Context; use C4::Auth qw( check_cookie_auth get_session ); diff --git a/tools/upload.pl b/tools/upload.pl old mode 100755 new mode 100644 index 1bbe2f97519..1301852c504 --- a/tools/upload.pl +++ b/tools/upload.pl @@ -19,7 +19,7 @@ use Modern::Perl; use CGI qw/-utf8/; -use JSON; +use JSON (); use C4::Auth qw( get_template_and_user ); use C4::Output qw( output_html_with_http_headers ); diff --git a/tools/viewlog.pl b/tools/viewlog.pl old mode 100755 new mode 100644 index a4ba8ed7f74..ed69df4e57d --- a/tools/viewlog.pl +++ b/tools/viewlog.pl @@ -24,16 +24,14 @@ use C4::Auth qw( get_template_and_user ); use CGI qw ( -utf8 ); use Text::CSV::Encoded; use C4::Context; -use C4::Koha; use C4::Output qw( output_html_with_http_headers ); -use C4::Items qw( sub ); use C4::Serials qw( CountSubscriptionFromBiblionumber ); -use C4::Debug; +use C4::Debug qw( $cgi_debug $debug ); use C4::Search qw( enabled_staff_search_views ); use Koha::ActionLogs; use Koha::Database; -use Koha::DateUtils; +use Koha::DateUtils qw( dt_from_string ); use Koha::Items; use Koha::Patrons; diff --git a/virtualshelves/addbybiblionumber.pl b/virtualshelves/addbybiblionumber.pl old mode 100755 new mode 100644 index 3c55e3c50e7..5c2b262a184 --- a/virtualshelves/addbybiblionumber.pl +++ b/virtualshelves/addbybiblionumber.pl @@ -59,7 +59,6 @@ addbybiblionumber.pl use Modern::Perl; use CGI qw ( -utf8 ); -use C4::Biblio; use C4::Output qw( output_html_with_http_headers ); use C4::Auth qw( get_template_and_user ); diff --git a/virtualshelves/downloadshelf.pl b/virtualshelves/downloadshelf.pl old mode 100755 new mode 100644 index b0091193abc..07b2682945f --- a/virtualshelves/downloadshelf.pl +++ b/virtualshelves/downloadshelf.pl @@ -20,14 +20,12 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Encode qw(encode); use C4::Auth qw( get_template_and_user ); use C4::Biblio qw( GetMarcBiblio ); -use C4::Items; use C4::Output qw( output_html_with_http_headers ); use C4::Record; -use C4::Ris; +use C4::Ris qw( marc2ris ); use Koha::CsvProfiles; use Koha::Virtualshelves; diff --git a/virtualshelves/sendshelf.pl b/virtualshelves/sendshelf.pl old mode 100755 new mode 100644 index a9518670516..38ba2595fe0 --- a/virtualshelves/sendshelf.pl +++ b/virtualshelves/sendshelf.pl @@ -20,13 +20,19 @@ use Modern::Perl; use CGI qw ( -utf8 ); -use Encode qw( encode ); -use Carp; -use Try::Tiny; +use Encode (); +use Carp qw( carp ); +use Try::Tiny qw( catch try ); use C4::Auth qw( get_template_and_user ); -use C4::Biblio qw( GetBiblioData GetMarcBiblio GetMarcAuthors GetMarcSubjects GetMarcISBN ); -use C4::Items qw( sub GetItemsInfo ); +use C4::Biblio qw( + GetBiblioData + GetMarcAuthors + GetMarcBiblio + GetMarcISBN + GetMarcSubjects +); +use C4::Items qw( GetItemsInfo ); use C4::Output qw( output_html_with_http_headers ); use Koha::Email; use Koha::Virtualshelves; diff --git a/virtualshelves/shelves.pl b/virtualshelves/shelves.pl old mode 100755 new mode 100644 index ac29aa1ae89..85a529e4928 --- a/virtualshelves/shelves.pl +++ b/virtualshelves/shelves.pl @@ -21,8 +21,13 @@ use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Biblio qw( GetMarcBiblio ); -use C4::Koha qw( getitemtypeimagelocation GetNormalizedUPC GetNormalizedEAN GetNormalizedOCLCNumber GetNormalizedISBN ); -use C4::Items qw( sub GetItemsLocationInfo ); +use C4::Koha qw( + GetNormalizedEAN + GetNormalizedISBN + GetNormalizedOCLCNumber + GetNormalizedUPC +); +use C4::Items qw( GetItemsLocationInfo ); use C4::Members; use C4::Output qw( pagination_bar output_html_with_http_headers ); use C4::XSLT; diff --git a/xt/author/show-template-structure.pl b/xt/author/show-template-structure.pl old mode 100755 new mode 100644 diff --git a/xt/yaml_valid.pl b/xt/yaml_valid.pl old mode 100755 new mode 100644 index 2bbb9650cbc..c5e3ba43684 --- a/xt/yaml_valid.pl +++ b/xt/yaml_valid.pl @@ -18,8 +18,8 @@ # along with Koha; if not, see . use Modern::Perl; -use Getopt::Long; -use YAML::XS; +use Getopt::Long qw( GetOptions ); +use YAML::XS (); my $usage = <