From 0ce0e2a279f6f39b6ce5f3b17699f285feca9ba1 Mon Sep 17 00:00:00 2001 From: "mkanat%bugzilla.org" <> Date: Fri, 16 Mar 2007 21:04:35 +0000 Subject: Bug 374215: Move all generally-useful Installation subroutines to Bugzilla::Install::Util Patch By Max Kanat-Alexander (module owner) a=mkanat --- Bugzilla/Install/DB.pm | 32 +------------------------------- 1 file changed, 1 insertion(+), 31 deletions(-) (limited to 'Bugzilla/Install/DB.pm') diff --git a/Bugzilla/Install/DB.pm b/Bugzilla/Install/DB.pm index 7d4939877..96bc161ac 100644 --- a/Bugzilla/Install/DB.pm +++ b/Bugzilla/Install/DB.pm @@ -25,6 +25,7 @@ use strict; use Bugzilla::Bug qw(is_open_state); use Bugzilla::Constants; use Bugzilla::Hook; +use Bugzilla::Install::Util qw(indicate_progress); use Bugzilla::Util; use Bugzilla::Series; @@ -32,23 +33,6 @@ use Date::Parse; use Date::Format; use IO::File; -use base qw(Exporter); -our @EXPORT_OK = qw( - indicate_progress -); - -sub indicate_progress { - my ($params) = @_; - my $current = $params->{current}; - my $total = $params->{total}; - my $every = $params->{every} || 1; - - print "." if !($current % $every); - if ($current % ($every * 60) == 0) { - print "$current/$total (" . int($current * 100 / $total) . "%)\n"; - } -} - # NOTE: This is NOT the function for general table updates. See # update_table_definitions for that. This is only for the fielddefs table. sub update_fielddefs_definition { @@ -2794,18 +2778,4 @@ Params: none Returns: nothing -=item C $total, current => $count, every => 1 })> - -Description: This prints out lines of dots as a long update is going on, - to let the user know where we are and that we're not frozen. - A new line of dots will start every 60 dots. - -Params: C - The total number of items we're processing. - C - The number of the current item we're processing. - C - How often the function should print out a dot. - For example, if this is 10, the function will print out - a dot every ten items. - -Returns: nothing - =back -- cgit v1.2.3-24-g4f1b