diff options
author | Einhard Leichtfuß | 2018-12-27 18:55:44 +0100 |
---|---|---|
committer | Einhard Leichtfuß | 2018-12-27 19:06:40 +0100 |
commit | dd137b37a572f28510be3cd7a74ec538ef692689 (patch) | |
tree | 1b30d22a8f47fe36c257aa456a72bffa23c84789 /post_webfilter.sed | |
parent | 8fe66d46bef882a390ba637a2be9a2172cd3f423 (diff) | |
download | aur-dd137b37a572f28510be3cd7a74ec538ef692689.tar.gz |
Add a few fixes to the dictionary source
A large part is derived from a diff between 0.48 and Debian's 0.48.5.
Also,
- split the sed script into one to be executed initially and another one
after webfilter.
- Use Debian's 0.48.5 instead of 0.48.4 (does not change much).
- Correctly set the version of the dictionary (as written by `dict -D').
- Do not patch the Makefile but execute the commands directly.
- Simplify prepare() and build().
- Add a check function.
Diffstat (limited to 'post_webfilter.sed')
-rwxr-xr-x | post_webfilter.sed | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/post_webfilter.sed b/post_webfilter.sed new file mode 100755 index 000000000000..7c3cdf8b7dd0 --- /dev/null +++ b/post_webfilter.sed @@ -0,0 +1,10 @@ +#!/usr/bin/env -S sed -Ef + +s`(<altname>|<contr>)<cref>([^<]*)</cref>`\1\2`g +s`(<stype>|<prod>)<ecol>([^<]*)</ecol>`\1\2`g + +# Restrict qau tag to the author themself. +s`<qau>([^<]*) (\([^)]{20}[^<]*)</qau>`<qau>\1</qau> \2`gp + +# Replace for example, '(<mcol><col>.+</col>), <col></col>(</mcol>)' -> '\1' +s`,?\s+<([^>]*)></\1>\s*``g |