diff options
author | Mark Oteiza <mvoteiza@udel.edu> | 2014-09-01 03:53:47 -0400 |
---|---|---|
committer | Peter Stephenson <p.w.stephenson@ntlworld.com> | 2014-09-01 20:00:47 +0100 |
commit | 7c7f00e6b1b0b2788eed535a9bfb6d42ac07b24a (patch) | |
tree | 4439d18f6fb4b8024e6c9679945dc448aad8b323 | |
parent | 4d0d6e8bed8e3583aaaaf1b34c85209031c95bbb (diff) | |
download | zsh-7c7f00e6b1b0b2788eed535a9bfb6d42ac07b24a.tar.gz zsh-7c7f00e6b1b0b2788eed535a9bfb6d42ac07b24a.tar.xz zsh-7c7f00e6b1b0b2788eed535a9bfb6d42ac07b24a.zip |
33081: suppress unnecessary error message
-rw-r--r-- | ChangeLog | 5 | ||||
-rwxr-xr-x | Completion/Unix/Type/_mime_types | 4 |
2 files changed, 7 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog index 29039ffd1..4c64256a9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -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> * unposted: Test/A05execution.ztst: further tweaking of the diff --git a/Completion/Unix/Type/_mime_types b/Completion/Unix/Type/_mime_types index b8ed889b8..18a332e09 100755 --- a/Completion/Unix/Type/_mime_types +++ b/Completion/Unix/Type/_mime_types @@ -33,10 +33,10 @@ if [[ $PREFIX = (#b)([^/]##)/* ]]; then compset -p $(( ${#maintype} + 1 )) _wanted mime-subtypes expl 'MIME subtype' \ compadd -- $(sed -ne "s%^\(type=\|\)${maintype}/\([^ ]*\).*$%\2%p" \ - $type_files) + $type_files 2>/dev/null) else # Search for main type. _wanted mime-types expl 'MIME 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 |