Changeset 246900a for app/src/tok
- Timestamp:
- 03/14/08 14:05:07 (17 years ago)
- Branches:
- master, help
- Children:
- b2647de
- Parents:
- 8d3e6ab
- git-author:
- pawelk <pawelk@…> (03/14/08 14:05:07)
- git-committer:
- pawelk <pawelk@…> (03/14/08 14:05:07)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
app/src/tok/tok
r25ae32e r246900a 7 7 my $help; 8 8 9 my $ configfile1=".../../conf/tok.conf";10 my $ configfile2="../conf/tok.conf";9 my $systemconfigfile='/usr/local/etc/utt/tok.conf'; 10 my $userconfigfile="$ENV{'HOME'}/.utt/tok.conf"; 11 11 12 12 #read configuration files########################### 13 13 my $file; 14 foreach $file ($ configfile1, $configfile2){14 foreach $file ($systemconfigfile, $userconfigfile){ 15 15 if(open(CONFIG, $configfile1)){ 16 16 while (<CONFIG>) { 17 chomp; 18 s/#.*//; 19 s/^\s+//; 20 s/\s+$//; 21 next unless length; 17 chomp; 18 s/#.*//; 19 s/^\s+//; 20 s/\s+$//; 21 next unless length; 22 22 my ($name, $value) = split(/\s*=\s*/, $_, 2); 23 23 if(($name eq "interactive")or($name eq "i")){ … … 27 27 $help=1; 28 28 } 29 } 29 } 30 30 close CONFIG; 31 31 } … … 56 56 while(<>) 57 57 { 58 1 while 58 1 while 59 59 / [[:alpha:]]+ (?{seg('W',$&)}) 60 60 | \d+ (?{seg('N',$&)}) … … 96 96 $offset += $len; 97 97 } 98
Note: See TracChangeset
for help on using the changeset viewer.