#!/usr/bin/env bash # Find and open pdf # -printf "%f\n" selected="$(find /home/h/doc/books/ -regex '.*\.\(pdf\|epub\|djvu\)' -type f | sort | fzf --delimiter=/ --with-nth=-1)" # Open and redirect output to /dev/null zathura "$selected" 2> /dev/null &