Debian Codegraph @

contrib/cliphist-fzf

raw symbols SCIP
1 #!/bin/shscip-shell filesystem . . `/bin/sh`.
2 # Outputs only unique lines and shows preview for the highlighted non-binary item
3
4 case "$1" in
5 preview)
6 # show preview if non-binary data
7 echoscip-shell system . . echo. "$2" | grepscip-shell system . . grep. -q '[\[ binary data .* \]\]' || echoscip-shell system . . echo. "$2" | cliphist decode
8 ;;
9 *)
10 exec cliphist list |
11 sortscip-shell system . . sort. -k 2 -u | # sort by 2 field to the end of line and output only unique lines
12 sortscip-shell system . . sort. -nr | # sort numerically in reverse
13 fzf --preview "$(realpathscip-shell system . . realpath. "$0") preview {}" |
14 cliphist decode |
15 wl-copy
16 ;;
17 esac