Merge pull request #1032 from luukvbaal/imgplugins

Add ucollage to imgview
This commit is contained in:
Piña Colada 2021-05-31 01:12:34 +05:30 committed by GitHub
commit 6eda83097a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 12 additions and 5 deletions

View File

@ -36,7 +36,7 @@ Plugins extend the capabilities of `nnn`. They are _executable_ scripts (or bina
| [hexview](hexview) | View a file in hex in `$PAGER` | sh | [hx](https://github.com/krpors/hx)/xxd |
| [imgresize](imgresize) | Resize images in dir to screen resolution | sh | [imgp](https://github.com/jarun/imgp) |
| [imgur](imgur) | Upload an image to imgur (from [imgur-screenshot](https://github.com/jomo/imgur-screenshot)) | bash | - |
| [imgview](imgview) | View (thumbnail)images, set wallpaper, [rename](https://github.com/jarun/nnn/wiki/Basic-use-cases#browse-rename-images) and [more](https://wiki.archlinux.org/index.php/Sxiv#Assigning_keyboard_shortcuts)| sh | [imv](https://github.com/eXeC64/imv)/[sxiv](https://github.com/muennich/sxiv)/[viu](https://github.com/atanunq/viu)/<br>[catimg](https://github.com/posva/catimg)/[lsix](https://github.com/hackerb9/lsix)|
| [imgview](imgview) | View (thumbnail)images, set wallpaper, [rename](https://github.com/jarun/nnn/wiki/Basic-use-cases#browse-rename-images) and [more](https://wiki.archlinux.org/index.php/Sxiv#Assigning_keyboard_shortcuts)| sh | [imv](https://github.com/eXeC64/imv)/[sxiv](https://github.com/muennich/sxiv)/[viu](https://github.com/atanunq/viu)/<br>[ucollage](https://github.com/ckardaris/ucollage)/[catimg](https://github.com/posva/catimg)/[lsix](https://github.com/hackerb9/lsix)|
| [ipinfo](ipinfo) | Fetch external IP address and whois information | sh | curl, whois |
| [kdeconnect](kdeconnect) | Send selected files to an Android device [✓] | sh | kdeconnect-cli |
| [launch](launch) | GUI application launcher | sh | fzf |

View File

@ -1,16 +1,18 @@
#!/usr/bin/env sh
# Description: Open hovered or current directory in image viewer.
# Thumbnails for audio and video files are generated
# and deleted on exit. Supported image viewers open
# in thumbnail mode when the hovered entry is a directory.
# Supported image viewers open in thumbnail mode when
# the hovered entry is a directory.
#
# Dependencies:
# - imv (https://github.com/eXeC64/imv) or,
# - sxiv (https://github.com/muennich/sxiv) or,
# - ucollage (https://github.com/ckardaris/ucollage) or,
# - lsix (https://github.com/hackerb9/lsix), or
# - viu (https://github.com/atanunq/viu), or
# - catimg (https://github.com/posva/catimg), or
# - lsix (https://github.com/hackerb9/lsix)
# - optional: ffmpegthumbnailer for video thumbnails
# - optional: ffmpeg for audio thumbnails (album art)
#
# Shell: POSIX compliant
# Author: Arun Prakash Jana, Luuk van Baal
@ -66,6 +68,11 @@ elif type lsix >/dev/null 2>&1; then
lsix
nthumb_cleanup
exit_prompt
elif type ucollage >/dev/null 2>&1; then
make_thumbs
ucollage
nthumb_cleanup
exit
elif type sxiv >/dev/null 2>&1; then
make_thumbs
if [ -f "$target" ]; then