#! /bin/bash # Search a given type of files for a string # File type to search export FILETYPE=$1 # String to search export SEARCH_STRING=$2 # The search find -name "*$FILETYPE" -exec grep "$SEARCH_STRING" {} \; -print