💾 Archived View for ait.place › dot › bin › .local › bin › dlocate.txt captured on 2022-04-28 at 18:10:10.

View Raw

More Information

⬅️ Previous capture (2021-12-03)

🚧 View Differences

-=-=-=-=-=-=-

#!/bin/bash

query=$@

#Prompt user if no query given
[ -z "$query" ] && query=$(printf "" | dmenu -p "Locate:")

#exit if input is empty
[ -z "$query" ] && exit 1

file="$(dmenu -l 20 < <(locate ${query}))" && $TERMINAL -e $FILE "$file"