Skip to content

Instantly share code, notes, and snippets.

@yegorius
Created March 23, 2019 15:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yegorius/eaef4cb69c33e5fd2921da028a901dd1 to your computer and use it in GitHub Desktop.
Save yegorius/eaef4cb69c33e5fd2921da028a901dd1 to your computer and use it in GitHub Desktop.
FZF dmenu
#!/usr/bin/env dash
TMPIN=$(mktemp -u)
mkfifo $TMPIN
STDOUT=$(readlink -f /proc/$$/fd/1)
termite --role=launcher --title=dmenu -e "dash -c \"fzf < $TMPIN > $STDOUT\"" 2>&- &
cat < /dev/stdin > $TMPIN
wait $!
rm $TMPIN
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment