Files
2026-06-23 00:23:16 +02:00

17 lines
378 B
Fish

function findstr
if test (count $argv) -lt 1
echo "Usage: findstr <search-string>"
return 1
end
if not command -q find
echo "findstr: 'find' is not installed."
return 1
end
if not command -q grep
echo "findstr: 'grep' is not installed."
return 1
end
find . -type f -exec grep -Hn "$argv[1]" {} \;
end