commit 3b8e1d672474f842ff111a03da9a9967e0da7f05
Author: ananthu <[email protected]>
Date: Fri Aug 28 10:38:44 2020 +0530
[dmenu](run-recent) fixed bug
diff --git a/tools.suckless.org/dmenu/scripts/run-recent
b/tools.suckless.org/dmenu/scripts/run-recent
index 7c81bc6f..6d57392d 100755
--- a/tools.suckless.org/dmenu/scripts/run-recent
+++ b/tools.suckless.org/dmenu/scripts/run-recent
@@ -7,7 +7,7 @@ cache="$cachedir/dmenu_recent"
touch "$cache"
-most_used=$(sort "$cache" | uniq -c | sort -r | cut -d" " -f8)
+most_used=$(sort "$cache" | uniq -c | sort -rh | awk -F" " '{print $2}')
run=$((echo "$most_used"; dmenu_path | grep -vxF "$most_used") | dmenu -i "$@")
([ -z "$run" ] || echo "$run"; head -n 99 "$cache") > "$cache.$$"
mv "$cache.$$" "$cache"