From 97c3b005a3852d1cc89822ef8a8f27aa13ef42df Mon Sep 17 00:00:00 2001 From: Florian Pritz Date: Sun, 9 Sep 2018 14:16:35 +0200 Subject: Use strictures instead of strict/warnings Signed-off-by: Florian Pritz --- cpanfile | 1 + lib/App/BorgRestore.pm | 3 +-- lib/App/BorgRestore/Borg.pm | 3 +-- lib/App/BorgRestore/DB.pm | 3 +-- lib/App/BorgRestore/Helper.pm | 3 +-- lib/App/BorgRestore/PathTimeTable/DB.pm | 3 +-- lib/App/BorgRestore/PathTimeTable/Memory.pm | 3 +-- lib/App/BorgRestore/Settings.pm | 3 +-- script/borg-restore.pl | 3 +-- t/cache_contains_data.t | 3 +-- t/compile.t | 2 +- t/find_archives.t | 3 +-- t/find_archives_mocked.t | 3 +-- t/handle_added_archives.t | 3 +-- t/handle_added_archives_with_db.t | 3 +-- t/helper/untaint.t | 3 +-- t/pod.t | 3 +-- t/pod_coverage.t | 3 +-- t/search_path.t | 3 +-- t/timespec_to_seconds.t | 3 +-- 20 files changed, 20 insertions(+), 37 deletions(-) diff --git a/cpanfile b/cpanfile index 26ea7cc..8c51b69 100644 --- a/cpanfile +++ b/cpanfile @@ -20,6 +20,7 @@ requires 'Pod::Usage'; requires 'Version::Compare'; requires 'autodie'; requires 'perl', 'v5.14.0'; +requires 'strictures'; on configure => sub { requires 'Devel::CheckBin'; diff --git a/lib/App/BorgRestore.pm b/lib/App/BorgRestore.pm index 04b563a..f95c71f 100644 --- a/lib/App/BorgRestore.pm +++ b/lib/App/BorgRestore.pm @@ -1,7 +1,6 @@ package App::BorgRestore; use v5.14; -use strict; -use warnings; +use strictures 2; our $VERSION = "3.1.0"; diff --git a/lib/App/BorgRestore/Borg.pm b/lib/App/BorgRestore/Borg.pm index 66c5705..62555fa 100644 --- a/lib/App/BorgRestore/Borg.pm +++ b/lib/App/BorgRestore/Borg.pm @@ -1,7 +1,6 @@ package App::BorgRestore::Borg; use v5.14; -use warnings; -use strict; +use strictures 2; use App::BorgRestore::Helper; diff --git a/lib/App/BorgRestore/DB.pm b/lib/App/BorgRestore/DB.pm index 6af14af..010f916 100644 --- a/lib/App/BorgRestore/DB.pm +++ b/lib/App/BorgRestore/DB.pm @@ -1,7 +1,6 @@ package App::BorgRestore::DB; use v5.14; -use strict; -use warnings; +use strictures 2; use App::BorgRestore::Helper; diff --git a/lib/App/BorgRestore/Helper.pm b/lib/App/BorgRestore/Helper.pm index 7e80218..869d4ee 100644 --- a/lib/App/BorgRestore/Helper.pm +++ b/lib/App/BorgRestore/Helper.pm @@ -1,7 +1,6 @@ package App::BorgRestore::Helper; use v5.14; -use strict; -use warnings; +use strictures 2; use autodie; use Function::Parameters; diff --git a/lib/App/BorgRestore/PathTimeTable/DB.pm b/lib/App/BorgRestore/PathTimeTable/DB.pm index 5d07ebc..1a24999 100644 --- a/lib/App/BorgRestore/PathTimeTable/DB.pm +++ b/lib/App/BorgRestore/PathTimeTable/DB.pm @@ -1,6 +1,5 @@ package App::BorgRestore::PathTimeTable::DB; -use strict; -use warnings; +use strictures 2; use Function::Parameters; use Log::Any qw($log); diff --git a/lib/App/BorgRestore/PathTimeTable/Memory.pm b/lib/App/BorgRestore/PathTimeTable/Memory.pm index 012e937..e84c4a4 100644 --- a/lib/App/BorgRestore/PathTimeTable/Memory.pm +++ b/lib/App/BorgRestore/PathTimeTable/Memory.pm @@ -1,7 +1,6 @@ package App::BorgRestore::PathTimeTable::Memory; use v5.14; -use strict; -use warnings; +use strictures 2; use Function::Parameters; diff --git a/lib/App/BorgRestore/Settings.pm b/lib/App/BorgRestore/Settings.pm index 81c2cac..0d9d015 100644 --- a/lib/App/BorgRestore/Settings.pm +++ b/lib/App/BorgRestore/Settings.pm @@ -1,7 +1,6 @@ package App::BorgRestore::Settings; use v5.14; -use strict; -use warnings; +use strictures 2; use App::BorgRestore::Helper; diff --git a/script/borg-restore.pl b/script/borg-restore.pl index 04f051d..f03fa22 100755 --- a/script/borg-restore.pl +++ b/script/borg-restore.pl @@ -1,6 +1,5 @@ #!/usr/bin/perl -T -use warnings; -use strict; +use strictures 2; =head1 NAME diff --git a/t/cache_contains_data.t b/t/cache_contains_data.t index 48832f4..425c875 100644 --- a/t/cache_contains_data.t +++ b/t/cache_contains_data.t @@ -1,5 +1,4 @@ -use strict; -use warnings; +use strictures 2; use Log::Any::Adapter ('TAP'); use Test::More; diff --git a/t/compile.t b/t/compile.t index 1a7a7a7..191d310 100644 --- a/t/compile.t +++ b/t/compile.t @@ -1,4 +1,4 @@ -use strict; +use strictures 2; use Test::More 0.98; use_ok $_ for qw( diff --git a/t/find_archives.t b/t/find_archives.t index e49cc2f..b10907e 100644 --- a/t/find_archives.t +++ b/t/find_archives.t @@ -1,5 +1,4 @@ -use strict; -use warnings; +use strictures 2; use Log::Any::Adapter ('TAP'); use Test::More; diff --git a/t/find_archives_mocked.t b/t/find_archives_mocked.t index a50c308..06e5a6f 100644 --- a/t/find_archives_mocked.t +++ b/t/find_archives_mocked.t @@ -1,5 +1,4 @@ -use strict; -use warnings; +use strictures 2; use Log::Any::Adapter ('TAP'); use Test::More; diff --git a/t/handle_added_archives.t b/t/handle_added_archives.t index d29c52a..d1dda74 100644 --- a/t/handle_added_archives.t +++ b/t/handle_added_archives.t @@ -1,5 +1,4 @@ -use strict; -use warnings; +use strictures 2; use Log::Any::Adapter ('TAP'); use POSIX qw(tzset); diff --git a/t/handle_added_archives_with_db.t b/t/handle_added_archives_with_db.t index 677953e..90c359c 100644 --- a/t/handle_added_archives_with_db.t +++ b/t/handle_added_archives_with_db.t @@ -1,5 +1,4 @@ -use strict; -use warnings; +use strictures 2; use Log::Any::Adapter ('TAP'); use POSIX qw(tzset); diff --git a/t/helper/untaint.t b/t/helper/untaint.t index 73b2c2b..0c2e36a 100644 --- a/t/helper/untaint.t +++ b/t/helper/untaint.t @@ -1,5 +1,4 @@ -use strict; -use warnings; +use strictures 2; use Log::Any::Adapter ('TAP'); use Test::More; diff --git a/t/pod.t b/t/pod.t index de15747..8da26be 100644 --- a/t/pod.t +++ b/t/pod.t @@ -1,5 +1,4 @@ -use strict; -use warnings; +use strictures 2; use Test::More; use Test::Pod; diff --git a/t/pod_coverage.t b/t/pod_coverage.t index fc346af..90a91ab 100644 --- a/t/pod_coverage.t +++ b/t/pod_coverage.t @@ -1,5 +1,4 @@ -use strict; -use warnings; +use strictures 2; use Test::More; use Test::Pod::Coverage; diff --git a/t/search_path.t b/t/search_path.t index 247b57f..bf5052f 100644 --- a/t/search_path.t +++ b/t/search_path.t @@ -1,5 +1,4 @@ -use strict; -use warnings; +use strictures 2; use Log::Any::Adapter ('TAP'); use Test::More; diff --git a/t/timespec_to_seconds.t b/t/timespec_to_seconds.t index 3724682..0f0a77c 100644 --- a/t/timespec_to_seconds.t +++ b/t/timespec_to_seconds.t @@ -1,5 +1,4 @@ -use strict; -use warnings; +use strictures 2; use Log::Any::Adapter ('TAP'); use Test::More; -- cgit v1.2.3-24-g4f1b