mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-25 12:23:09 +00:00
Tweak lexicon_filter.in for GNU sed
This commit is contained in:
parent
b592da41f6
commit
47c357a354
2 changed files with 3 additions and 3 deletions
|
@ -414,7 +414,7 @@ lexicon_filter: lexicon.txt lexicon_filter.in
|
||||||
if echo x | $(SED) "/[[:<:]]x/d" 2>/dev/null; then \
|
if echo x | $(SED) "/[[:<:]]x/d" 2>/dev/null; then \
|
||||||
WORDBL='[[:<:]]'; WORDBR='[[:>:]]'; \
|
WORDBL='[[:<:]]'; WORDBR='[[:>:]]'; \
|
||||||
else \
|
else \
|
||||||
WORDBL='\<'; WORDBR='\>'; \
|
WORDBL='\\<'; WORDBR='\\>'; \
|
||||||
fi; \
|
fi; \
|
||||||
$(SED) <lexicon.txt >>$@.tmp -n \
|
$(SED) <lexicon.txt >>$@.tmp -n \
|
||||||
-e "s|^\([a-z][a-z][a-z][a-z]\) \([a-z_-]*\)$$|s,$$WORDBL\2$$WORDBR,@\1{\2},g|p" \
|
-e "s|^\([a-z][a-z][a-z][a-z]\) \([a-z_-]*\)$$|s,$$WORDBL\2$$WORDBR,@\1{\2},g|p" \
|
||||||
|
|
|
@ -530,7 +530,7 @@ s/\n$//g
|
||||||
# characters. Basically the inverse of the 'patternflush' action, with
|
# characters. Basically the inverse of the 'patternflush' action, with
|
||||||
# additional trailing characters stripped.
|
# additional trailing characters stripped.
|
||||||
x
|
x
|
||||||
/^\<@[^}]*$/ ! {
|
/^<@[^}]*$/ ! {
|
||||||
s/[^\<]*//
|
s/[^\<]*//
|
||||||
s/^ *\\\n//g
|
s/^ *\\\n//g
|
||||||
s/\n *\\//g
|
s/\n *\\//g
|
||||||
|
@ -551,7 +551,7 @@ x
|
||||||
}
|
}
|
||||||
s/\\\n/\
|
s/\\\n/\
|
||||||
/
|
/
|
||||||
s/\< \n//
|
s/< \n//
|
||||||
s/^[a-z][a-z]* \n//
|
s/^[a-z][a-z]* \n//
|
||||||
#.
|
#.
|
||||||
# Swap the buffers back.
|
# Swap the buffers back.
|
||||||
|
|
Loading…
Reference in a new issue