config/.config/fish/functions/mansearch.fish

5 lines
228 B
Fish

function mansearch --description 'Full-text search of man pages'
# -F is used to match literally (no regex)
command rg -z -F $argv (manpath | string split :) -l | command sed -r 's@.*/(.*)\.([0-9]+)(\.gz)?@\1(\2)@g'
end