git clone https://git.lucas.co/fontpreview.git
use better regex for awk, credits: @SmartFinn
fontpreview | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fontpreview b/fontpreview
index 40cb8bc..7e21128 100755
--- a/fontpreview
+++ b/fontpreview
@@ -98,7 +98,7 @@ main(){
while true; do
# List out all the fonts which imagemagick is able to find, extract
# the font names and then pass them to fzf
- font=$(convert -list font | awk -F: '/^\s *Font: /{print substr($NF,2)}' | fzf --prompt="$SEARCH_PROMPT")
+ font=$(convert -list font | awk -F: '/^\s *Font: /{print substr($NF,2)}' | fzf --prompt="$SEARCH_PROMPT")
# Exit if nothing is returned by fzf, which also means that the user
# has pressed [ESCAPE]