Changeset 246900a for app/src/kot
- 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/kot/kot
r25ae32e r246900a 8 8 my $spaces=0; 9 9 10 my $ configfile1="../../conf/kot.conf";11 my $ configfile2="../conf/kot.conf";10 my $systemconfigfile='/usr/local/etc/utt/kot.conf'; 11 my $userconfigfile="$ENV{'HOME'}/.utt/kot.conf"; 12 12 13 13 #read configuration files########################### 14 14 my $file; 15 foreach $file ($ configfile1, $configfile2){15 foreach $file ($systemconfigfile, $userconfigfile){ 16 16 if(open(CONFIG, $file)){ 17 17 while (<CONFIG>) { 18 chomp; 19 s/#.*//; 20 s/^\s+//; 21 s/\s+$//; 22 next unless length; 18 chomp; 19 s/#.*//; 20 s/^\s+//; 21 s/\s+$//; 22 next unless length; 23 23 my ($name, $value) = split(/\s*=\s*/, $_, 2); 24 24 if(($name eq "gap-fill")or($name eq "g")){ … … 31 31 $help=1; 32 32 } 33 34 } 33 34 } 35 35 close CONFIG; 36 36 } … … 49 49 Options: 50 50 --gap-fill -g Help. 51 --spaces -r 51 --spaces -r 52 52 --define=FILE Read macrodefinitions from FILE. 53 53 --flex-template=FILE Read flex code template from FILE. … … 71 71 { 72 72 my ($start,$len,$type,$form) = /^\s*(\d+)\s+(\d+)\s+(\S+)\s+(\S+)/; 73 73 74 74 if($start > $prevend) 75 75 { … … 78 78 79 79 $prevend=$start+$len; 80 80 81 81 next if $len==0;# || $form eq "*"; 82 82 … … 94 94 print $form; 95 95 } 96 97 #print $gap_fill;98 99 # print "\n";
Note: See TracChangeset
for help on using the changeset viewer.