summaryrefslogtreecommitdiff
path: root/.config/sxiv/exec/key-handler
diff options
context:
space:
mode:
authorGustaf Rydholm <gustaf.rydholm@gmail.com>2024-09-25 00:38:58 +0200
committerGustaf Rydholm <gustaf.rydholm@gmail.com>2024-09-25 00:38:58 +0200
commitee3167c8a90341dc4d8eb911f72d5430173f3719 (patch)
treec8df20a31fd303e1393c2f439d01cfae50a6377b /.config/sxiv/exec/key-handler
parentc1415cada7b971180d74612fb5f9eb7f64d1abda (diff)
Replace sxiv with nsxiv
Diffstat (limited to '.config/sxiv/exec/key-handler')
-rw-r--r--.config/sxiv/exec/key-handler33
1 files changed, 0 insertions, 33 deletions
diff --git a/.config/sxiv/exec/key-handler b/.config/sxiv/exec/key-handler
deleted file mode 100644
index 3d9565f..0000000
--- a/.config/sxiv/exec/key-handler
+++ /dev/null
@@ -1,33 +0,0 @@
-#!/bin/sh
-while read file
-do
- case "$1" in
- "w") setbg "$file" & ;;
- "c")
- [ -z "$destdir" ] && destdir="$(sed "s/\s.*#.*$//;/^\s*$/d" ${XDG_CONFIG_HOME:-$HOME/.config}/shell/bm-dirs | awk '{print $2}' | dmenu -l 20 -i -p "Copy file(s) to where?" | sed "s|~|$HOME|g")"
- [ ! -d "$destdir" ] && notify-send "$destdir is not a directory, cancelled." && exit
- cp "$file" "$destdir" && notify-send -i "$(readlink -f "$file")" "$file copied to $destdir." &
- ;;
- "m")
- [ -z "$destdir" ] && destdir="$(sed "s/\s.*#.*$//;/^\s*$/d" ${XDG_CONFIG_HOME:-$HOME/.config}/shell/bm-dirs | awk '{print $2}' | dmenu -l 20 -i -p "Move file(s) to where?" | sed "s|~|$HOME|g")"
- [ ! -d "$destdir" ] && notify-send "$destdir is not a directory, cancelled." && exit
- mv "$file" "$destdir" && notify-send -i "$(readlink -f "$file")" "$file moved to $destdir." &
- ;;
- "r")
- convert -rotate 90 "$file" "$file" ;;
- "R")
- convert -rotate -90 "$file" "$file" ;;
- "f")
- convert -flop "$file" "$file" ;;
- "y")
- echo -n "$file" | tr -d '\n' | xclip -selection clipboard &&
- notify-send "$file copied to clipboard" & ;;
- "Y")
- readlink -f "$file" | tr -d '\n' | xclip -selection clipboard &&
- notify-send "$(readlink -f "$file") copied to clipboard" & ;;
- "d")
- [ "$(printf "No\\nYes" | dmenu -i -p "Really delete $file?")" = "Yes" ] && rm "$file" && notify-send "$file deleted." ;;
- "g") ifinstalled gimp && setsid -f gimp "$file" ;;
- "i") notify-send "File information" "$(mediainfo "$file")" ;;
- esac
-done