2 # mkcomp --- make completion files
4 # Usage: mkcomp <template file>
7 # Output list of file extensions from all input files, one per line.
8 # Delete lines beginning with `#', empty lines, and strip leading and
19 # print regex of the file extensions from all input files
25 while read -r line
; do
26 if test -n "$line"; then
27 if test $n -eq 0; then
38 # combine llpp.in and llppac.in if making a llppac completion
41 if test "$(basename "$f")" = llppac
; then
44 re
="$(print_regex llpp.in $llppac)"
46 sed -e "s/@re@/$re/g" "$f.mk" > "$f"
47 printf "wrote: %s\n" "$f"