Changeset 28779 for gs2-extensions

Show
Ignore:
Timestamp:
18.12.2013 13:02:19 (6 years ago)
Author:
jmt12
Message:

Making timing message all sorts of purty

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • gs2-extensions/parallel-building/trunk/src/perllib/parallelbuildinginexport.pm

    r28778 r28779  
    5757    my $end_time = [&gettimeofday()]; 
    5858    my $duration = tv_interval($start_time, $end_time); 
     59    print &makeHeader('Parallel Import Complete') . "\n"; 
     60    print '  Ended:    ' . @{$end_time}[0] . '.' . @{$end_time}[1] . "\n"; 
    5961    print '  Duration: ' . sprintf('%0.6f', $duration) . "\n"; 
     62    print '=' x 80 . "\n"; 
    6063  } 
    6164} 
     
    137140    print '  Workers:   ' . $self->{'workers'} . "\n"; 
    138141    print '  Batchsize: ' . $self->{'batchsize'} . "\n"; 
    139     print '=' x 79 . "\n"; 
     142    print '=' x 80 . "\n"; 
    140143    if (!$self->{'removeold'}) 
    141144    { 
     
    347350# 
    348351# @param $msg The message to center as a string 
    349 # @param $length The desired length of string - defaults to 79 
     352# @param $length The desired length of string - defaults to 80 
    350353# @return A string centered with '=' as padding 
    351354# 
     
    355358  if (!defined $length) 
    356359  { 
    357     $length = 79; # 80 with newline 
     360    $length = 80; 
    358361  } 
    359362  my $filler_length = ($length - 2 - length($msg)) / 2; 
    360363  my $filler = '=' x $filler_length; 
    361   if (length($msg) % 2 == 0) 
     364  if (length($msg) % 2 == 1) 
    362365  { 
    363366    $msg = $filler . ' ' . $msg . ' =' . $filler;