1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2025-01-23 00:41:03 +01:00

33081: suppress unnecessary error message

This commit is contained in:
Mark Oteiza 2014-09-01 03:53:47 -04:00 committed by Peter Stephenson
parent 4d0d6e8bed
commit 7c7f00e6b1
2 changed files with 7 additions and 2 deletions

View file

@ -1,3 +1,8 @@
2014-09-01 Peter Stephenson <p.w.stephenson@ntlworld.com>
* Mark Oteiza: 33081: Completion/Unix/Type/_mime_types: suppress
error message if unnecessary file not found.
2014-08-31 Barton E. Schaefer <schaefer@zsh.org> 2014-08-31 Barton E. Schaefer <schaefer@zsh.org>
* unposted: Test/A05execution.ztst: further tweaking of the * unposted: Test/A05execution.ztst: further tweaking of the

View file

@ -33,10 +33,10 @@ if [[ $PREFIX = (#b)([^/]##)/* ]]; then
compset -p $(( ${#maintype} + 1 )) compset -p $(( ${#maintype} + 1 ))
_wanted mime-subtypes expl 'MIME subtype' \ _wanted mime-subtypes expl 'MIME subtype' \
compadd -- $(sed -ne "s%^\(type=\|\)${maintype}/\([^ ]*\).*$%\2%p" \ compadd -- $(sed -ne "s%^\(type=\|\)${maintype}/\([^ ]*\).*$%\2%p" \
$type_files) $type_files 2>/dev/null)
else else
# Search for main type. # Search for main type.
_wanted mime-types expl 'MIME type' \ _wanted mime-types expl 'MIME type' \
compadd -S/ -- $(sed -ne "s/^type=//" \ compadd -S/ -- $(sed -ne "s/^type=//" \
-e "s%^\(${PREFIX:-[a-z]}[^=\"]*\)/.*$%\1%p" $type_files) -e "s%^\(${PREFIX:-[a-z]}[^=\"]*\)/.*$%\1%p" $type_files 2>/dev/null)
fi fi