diff --git a/saury b/saury index 30bfbef..d546f7e 100755 --- a/saury +++ b/saury @@ -102,7 +102,12 @@ function aur_search set_color --bold echo -n (string join "" \ (set_color CC3399) "aur/" \ - (set_color normal; set_color --bold) "$name") + (set_color normal; set_color --bold) (string replace -a -i \ + "$query" \ + (string join "" (set_color 33CCB3) \ + "$query" \ + (set_color normal; set_color --bold)) \ + "$name")) echo -n ' ' if test $out_of_date = "true" @@ -144,7 +149,12 @@ function aur_search echo set_color normal - echo " $description" + echo (string replace -a -i \ + "$query" \ + (string join "" (set_color 33CCB3) \ + "$query" \ + (set_color normal)) \ + " $description") end else if test "$rpc_response_type" = "error" set rpc_error (echo $rpc_response | jq -r '.error')