git://git.nikiroo.be
/
gofetch.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
14f6746
)
gopher.sh: rename ImageUtils.sh -> img2aa
author
Niki Roo
<niki@nikiroo.be>
Tue, 10 Apr 2018 07:14:40 +0000
(09:14 +0200)
committer
Niki Roo
<niki@nikiroo.be>
Tue, 10 Apr 2018 07:14:40 +0000
(09:14 +0200)
gopher.sh
patch
|
blob
|
blame
|
history
diff --git
a/gopher.sh
b/gopher.sh
index 81c5b0947b3c3f6d69975fd7b8da6ee1e0933e7f..c026b9c9839226c14ce2a7f7f706b40c2ec10a1f 100755
(executable)
--- a/
gopher.sh
+++ b/
gopher.sh
@@
-142,21
+142,21
@@
download)
echo "<BINARY FILE>" | less
;;
g|I)
echo "<BINARY FILE>" | less
;;
g|I)
- if
convert -h
>/dev/null 2>&1; then
- i
f ImageUtils.sh --help >/dev/null 2>&1; then
- ImageUtils.sh --mode=DITHERING \
- --width=74 "$tmp" | less
-
elif jp2a
-h >/dev/null 2>&1; then
+ if
img2aa --help
>/dev/null 2>&1; then
+ i
mg2aa --mode=DITHERING \
+ --width=74 "$tmp" | less
+ elif jp2a -h >/dev/null 2>&1; then
+
if convert
-h >/dev/null 2>&1; then
convert "$tmp" "$tmp.jpg"
jp2a --border --chars=" .-+=o8#"\
--width=74 "$tmp.jpg" | less
else
convert "$tmp" "$tmp.jpg"
jp2a --border --chars=" .-+=o8#"\
--width=74 "$tmp.jpg" | less
else
- echo "required program not found to view images:" \
-
jp2a or ImageUtils.sh
| less
+ echo "required program not found to view images:
convert
" \
+ | less
fi
else
fi
else
- echo "required program not found to view images:
convert
" \
- | less
+ echo "required program not found to view images:" \
+
jp2a or img2aa
| less
fi
;;
*)
fi
;;
*)