Fixes #1421, when a tool has no OPTSWITHARGS it will produce invalid bash (completion) output syntax

This commit is contained in:
Sean Enck 2018-07-06 15:29:26 -04:00 committed by Frank Morgner
parent a6b4605b86
commit 0ceef8778b
1 changed files with 1 additions and 1 deletions

View File

@ -36,7 +36,7 @@ tools.html: $(srcdir)/tools.xml $(wildcard $(srcdir)/*.1.xml) $(wildcard $(srcdi
| sort -u | grep -- '^\-' | tr '\n' ' ')," \
| sed "s,OPTSWITHARGS,\
$(shell sed -n 's,.*<option>\([^<]*\)</option>.*<replaceable>.*,\1,pg' $< \
| sort -u | grep -- '^\-' | tr '\n' '|' | sed 's,|$$,,')," \
| sort -u | grep -- '^\-' | tr '\n' '|' | sed 's,|$$,,' | grep ^ || echo "!*")," \
| sed "s,FILEOPTS,\
$(shell sed -n 's,.*<option>\([^<]*\)</option>.*<replaceable>.*filename.*,\1,pg' $< \
| sort -u | grep -- '^\-' | tr '\n' '|' | sed 's,|$$,,' | grep ^ || echo "!*")," \