blob: 4c2a5b4b8ffeda103c2e1c2b230489b0b8308335 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
#!/bin/sh
cachedir="${XDG_CACHE_HOME:-"$HOME/.cache"}"
cache="$cachedir/dmenu_run"
configdir="${XDG_CONFIG_HOME:-"$HOME/.config/dmenu"}"
config="$configdir/dmenu_omitlist"
[ ! -e "$cachedir" ] && mkdir -p "$cachedir"
[ ! -e "$configdir" ] && mkdir -p "$configdir"
IFS=:
if stest -dqr -n "$cache" $PATH; then
stest -flx $PATH | sort -u | grep -wvF -f $config | tee "$cache"
else
cat "$cache"
fi
|