mirror of
https://github.com/agresdominik/dotfiles.git
synced 2026-04-21 18:05:50 +00:00
19 lines
283 B
Bash
Executable File
19 lines
283 B
Bash
Executable File
#!/bin/sh
|
|
file=$(
|
|
cd "$HOME/documents" || exit 1
|
|
fd --type f . | rofi -dmenu -i -p "documents"
|
|
) || exit 0
|
|
|
|
[ -n "$file" ] || exit 0
|
|
|
|
path="$HOME/documents/$file"
|
|
|
|
case "$path" in
|
|
*.pdf|*.PDF)
|
|
exec zathura "$path"
|
|
;;
|
|
*)
|
|
exec alacritty -e nvim "$path"
|
|
;;
|
|
esac
|