committer@tuxwarrior
2025-05-13 17:12:28 -05:00
parent 41a9c6c81e
commit 1baa204f50

View File

@@ -114,16 +114,15 @@ cmd recol %{{
#cmd trash %set -f; mv $fx ~/.trash
# $f: single file, $fx: multiple files
# https://github.com/gokcehan/lf/issues/45#issuecomment-260347057
cmd trash %tp.sh "$fx"
# IFS=':'; echo $fs | tr " " "\n"
# https://github.com/gokcehan/lf/issues/45#issuecomment-260347057
# https://unix.stackexchange.com/questions/617576/read-from-terminal-without-waiting-for-enter
cmd trash-confirm ${{
echo 'file(s) selected:'
echo $fx
echo 'delete? [y/n]'
read ans
read -n1 ans
[ $ans = 'y' ] && (echo 'deleting files…' && trash %tp.sh "$fx") || echo 'cancelled…'
}}