commit 601c29e0e9364b9b4500e24f37118ed3cf7f6630
parent 2cd32e7247f1babad2726551a43b521a91bc76f4
Author: Andreas Guldstrand <andreas.guldstrand@gmail.com>
Date: Sun, 6 Dec 2015 04:14:07 +0100
Change from @EXPORT to @EXPORT_OK
Diffstat:
10 files changed, 16 insertions(+), 12 deletions(-)
diff --git a/SBO-Lib/lib/SBO/Lib.pm b/SBO-Lib/lib/SBO/Lib.pm
@@ -17,9 +17,9 @@ use warnings FATAL => 'all';
package SBO::Lib;
our $VERSION = '1.9';
-require Exporter;
-our @ISA = qw(Exporter);
-our @EXPORT = qw(
+use Exporter 'import';
+
+our @EXPORT_OK = qw(
script_error
open_fh
open_read
@@ -60,6 +60,10 @@ our @EXPORT = qw(
%config
);
+our %EXPORT_TAGS = (
+ all => \@EXPORT_OK,
+);
+
use constant {
_ERR_USAGE => 1, # usage errors
_ERR_SCRIPT => 2, # errors with the scripts themselves
diff --git a/sbocheck b/sbocheck
@@ -12,7 +12,7 @@
use 5.16.0;
use strict;
use warnings FATAL => 'all';
-use SBO::Lib;
+use SBO::Lib qw/ update_tree get_available_updates script_error open_fh /;
use Getopt::Long;
use File::Basename;
use List::Util 'max';
diff --git a/sboclean b/sboclean
@@ -12,7 +12,7 @@
use 5.16.0;
use strict;
use warnings FATAL => 'all';
-use SBO::Lib;
+use SBO::Lib qw/ usage_error script_error /;
use File::Basename;
use Getopt::Long qw(:config bundling);
use File::Path qw(remove_tree);
diff --git a/sboconfig b/sboconfig
@@ -12,7 +12,7 @@
use 5.16.0;
use strict;
use warnings FATAL => 'all';
-use SBO::Lib;
+use SBO::Lib qw/ usage_error script_error $tempdir open_fh %config $conf_dir $conf_file /;
use File::Basename;
use Getopt::Long;
use File::Copy;
diff --git a/sbofind b/sbofind
@@ -13,7 +13,7 @@
use 5.16.0;
use strict;
use warnings FATAL => 'all';
-use SBO::Lib;
+use SBO::Lib qw/ slackbuilds_or_fetch script_error open_read get_build_queue %config /;
use File::Basename;
use Getopt::Long qw(:config bundling);
diff --git a/sboinstall b/sboinstall
@@ -12,7 +12,7 @@
use 5.16.0;
use strict;
use warnings FATAL => 'all';
-use SBO::Lib;
+use SBO::Lib qw/ usage_error slackbuilds_or_fetch get_build_queue merge_queues get_sbo_locations get_installed_packages get_inst_names get_installed_cpans get_sbo_location user_prompt process_sbos print_failures %config get_arch /;
use Getopt::Long qw(:config bundling);
use File::Basename;
diff --git a/sboremove b/sboremove
@@ -12,7 +12,7 @@
use 5.16.0;
use strict;
use warnings FATAL => 'all';
-use SBO::Lib;
+use SBO::Lib qw/ get_inst_names get_installed_packages get_sbo_location get_build_queue merge_queues get_requires get_readme_contents get_sbo_location /;
use Getopt::Long qw(:config bundling);
use File::Basename;
diff --git a/sbosnap b/sbosnap
@@ -12,7 +12,7 @@
use 5.16.0;
use strict;
use warnings FATAL => 'all';
-use SBO::Lib;
+use SBO::Lib qw/ fetch_tree update_tree %config /;
use File::Basename;
use Getopt::Long;
diff --git a/sboupgrade b/sboupgrade
@@ -12,7 +12,7 @@
use 5.16.0;
use strict;
use warnings FATAL => 'all';
-use SBO::Lib;
+use SBO::Lib qw/ get_available_updates usage_error slackbuilds_or_fetch uniq get_sbo_location get_inst_names get_installed_packages get_build_queue get_sbo_locations merge_queues user_prompt process_sbos print_failures %config /;
use Getopt::Long qw(:config bundling);
use File::Basename;
use File::Copy;
diff --git a/t/test.t b/t/test.t
@@ -8,7 +8,7 @@ use Test::More;
use File::Copy;
use Text::Diff;
use lib ".";
-use SBO::Lib;
+use SBO::Lib qw/ :all /;
chomp(my $pwd = `pwd`);
my $sbo_home = "$pwd/sbo";