Changeset 29161
- Timestamp:
- 2014-07-24T14:13:19+12:00 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
gs2-extensions/parallel-building/trunk/src/perllib/plugins/CPULoadTextPlugin.pm
r28649 r29161 7 7 no strict 'subs'; 8 8 9 sub BEGIN 10 { 11 @CPULoadTextPlugin::ISA = ('TextPlugin'); 12 13 eval('use Crypt::Blowfish_PP'); 14 if ($@) 15 { 16 # We need the Perl version before continuing 17 if (!defined $ENV{'PERL_VERSION'}) 18 { 19 $ENV{'PERL_VERSION'} = `perl -S $ENV{'GEXTPARALLELBUILDING'}/bin/script/perl-version.pl`; 20 } 21 die "PERL_VERSION not set\n" unless defined $ENV{'PERL_VERSION'}; 22 # Crypt::Blowfish_PP module 23 unshift (@INC, $ENV{'GEXTPARALLELBUILDING'} . '/' . $ENV{'GSDLOS'} . '/lib/perl/' . $ENV{'PERL_VERSION'}); 24 } 25 } 26 9 27 use Crypt::Blowfish_PP; 10 28 use Kea; 11 29 use Lingua::EN::Syllable; 12 13 sub BEGIN {14 @CPULoadTextPlugin::ISA = ('TextPlugin');15 }16 30 17 31 our $cpu_load_list = [ { 'name' => "none", … … 98 112 $self->{'first'} = '80,256,1024'; 99 113 $self->generateSummaries($doc_obj, $textref); 114 $self->{'first'} = undef; 100 115 $self->generateComplexity($doc_obj, $textref); 101 116 $self->generateEncryptedText($doc_obj, $textref, 'thePassword'); … … 249 264 my ($doc_obj, $text) = @_; 250 265 my $raw_lexicon = {}; 251 my @words = split( '/[\,\.\s]+/', $text);266 my @words = split(/[\,\.\s]+/, $text); 252 267 foreach my $word (@words) 253 268 {
Note:
See TracChangeset
for help on using the changeset viewer.