From 41e27dcfdd841622dc5bd90dfc96115189bf0d58 Mon Sep 17 00:00:00 2001 From: littleblack111 Date: Tue, 8 Oct 2024 23:31:21 +0800 Subject: fix(cliphist-rofi-img): made it faster by only getting 100 linesa --- dot-config/rofi/scripts/cliphist-rofi-img | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/dot-config/rofi/scripts/cliphist-rofi-img b/dot-config/rofi/scripts/cliphist-rofi-img index c30a627d..70a32aa9 100755 --- a/dot-config/rofi/scripts/cliphist-rofi-img +++ b/dot-config/rofi/scripts/cliphist-rofi-img @@ -19,7 +19,9 @@ match(\$0, /^([0-9]+)\s(\[\[\s)?binary.*(jpg|jpeg|png|bmp)/, grp) { 1 EOF # echo $(cat "$tmp_dir/cliphist") -# get last 10 lines and merge them +# format: \t<100 char preview> remove the ID + + # cat "$tmp_dir/cliphist" -cliphist list | gawk "$prog" & +cliphist list | head -n 100 | gawk "$prog" & -- cgit v1.2.3