Skip to content

Commit

Permalink
Added proper interpretation of infostrings/weights.
Browse files Browse the repository at this point in the history
  • Loading branch information
aarppe committed Nov 8, 2024
1 parent 3d3402e commit 871093a
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions tools/shellscripts/add-lexicon-and-tag-flags-2-lexc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -87,11 +87,12 @@ END {
gsub("0", "%0", lexflag);
}
else
if(match(line[i], "^([^!;]+)(;)(.*)$", f)!=0)
if(match(line[i], "^([^!;\"]+)(\"[^\"]+\"[ ]*)?([!;])(.*)$", f)!=0)
{
content=f[1];
sep=f[2];
comment=f[3];
infostr=f[2];
sep=f[3];
comment=f[4];
n=split(content, ff, ":")
if(n==2)
Expand Down Expand Up @@ -177,7 +178,7 @@ END {
}
}
print content sep comment;
printf "%s%s%s%s\n", content, infostr, sep, comment;
}
else
Expand Down

0 comments on commit 871093a

Please sign in to comment.