fzfsample: add N parameter
This commit is contained in:
@ -1,4 +1,8 @@
|
||||
#!/bin/bash
|
||||
#!/bin/zsh
|
||||
|
||||
selection=$(fzf --preview 'mpv --no-video {}' --preview-window=up:20%)
|
||||
FILES=$(fd . | grep "\(wav\|mp3\)$" | sort -R)
|
||||
if [[ $1 ]]; then
|
||||
FILES=$(echo $FILES | head -n $1)
|
||||
fi
|
||||
selection=$(echo $FILES | fzf --preview "mpv --no-video {}" --preview-window=up:20%)
|
||||
dragon-drop --and-exit "$selection"
|
||||
|
||||
Reference in New Issue
Block a user