Changeset 428

Show
Ignore:
Timestamp:
01/09/07 15:01:35 (6 years ago)
Author:
lincoln
Message:

reduce dependencies

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • postprocessors/imdb_augment_data

    r314 r428  
    2828 
    2929use LWP::UserAgent; 
    30 use Time::HiRes qw(gettimeofday tv_interval); 
    3130use XMLTV; 
    32 use XMLTV::ProgressBar; 
    3331use POSIX qw(strftime mktime); 
    3432use Getopt::Long; 
     
    3735use Compress::Zlib; 
    3836use DateTime::Format::Strptime; 
    39 use Cwd; 
    4037 
    4138# 
     
    4340# 
    4441 
    45 my $script_start_time = [gettimeofday]; 
     42my $script_start_time = time; 
    4643my %stats; 
    4744my $data_cache; 
     
    6562 
    6663my $opt = { }; 
    67 $opt->{output_file} =           cwd() . "/output.xmltv"; 
    68 $opt->{cache_file} =            cwd() . "/imdb_augment_data.cache"; 
     64$opt->{output_file} =           "output.xmltv"; 
     65$opt->{cache_file} =            "imdb_augment_data.cache"; 
    6966$opt->{lang} =                  "en"; 
    7067$opt->{debug} =                 0; 
     
    316313sub print_stats 
    317314{ 
    318         printf "STATS: %s v%s completed in %0.2f seconds", 
    319           $progname, $version, tv_interval($script_start_time); 
     315        my $now = time; 
     316        printf "STATS: %s v%s completed in %d seconds", 
     317          $progname, $version, ($now-$script_start_time); 
    320318        foreach my $key (sort keys %stats) { 
    321319                printf ", %d %s",$stats{$key},$key;