bash script to search directory only specific file types : <p>I'm trying to write a bash script that will search a folder for specific file extensions (lets say .txt and .csv). The folder can have thousands of each type of extension. If the folder has only these two extensions across all files then the script can proceed. If any other extensions are present (and the two allowed extesions may also be preset), the script copies the folder to a holding bucket and writes to a log file.
The folder that is being searched will never have subfolders.</p>

<p>So, if the folder has:
.txt and .csv, this passes
If the folder has:
.mp3, this fails
If the folder has:
.txt, .csv and .mp3, this also fails.</p>

<p>Thanks!</p>
