zshrc: add support for `fetch' in simple-extract()
authorMoviuro <moviuro+grml@gmail.com>
Wed, 22 Apr 2015 22:08:05 +0000 (00:08 +0200)
committerMichael Prokop <mika@grml.org>
Tue, 2 Jun 2015 15:43:16 +0000 (17:43 +0200)
`fetch` is FreeBSD's default utility to download things

etc/zsh/zshrc

index be62172..8e1ec13 100644 (file)
@@ -3306,8 +3306,10 @@ simple-extract() {
                 WGET_CMD="curl -L -s -o -"
             elif check_com wget; then
                 WGET_CMD="wget -q -O -"
+            elif check_com fetch; then
+                WGET_CMD="fetch -q -o -"
             else
-                print "ERROR: neither wget nor curl is installed" >&2
+                print "ERROR: neither wget, curl nor fetch is installed" >&2
                 RC=$((RC+4))
                 continue
             fi