Shell File extensions, detect and convert via console

I have a peculiar problem that I can't quite figure out how to solve.

I have around 500 folders, each of which contain 2,000 files each. Each file is of a different document type, i.e. .rtf, pdf and .doc mainly.

The issue is that none of the files have an extension present in the file name.

In a GUI (Xfce currently) this is not so much of an issue if all one wants to do is open the file it is automatically recognized if the requisite software is installed.

However, it is impossible to use batch conversion tools because they mostly require a file extension to be present.

Thus my question is, is there some sort of recursive way via the console to enter each folder, automatically detect the file extension and simply add the extension to the filename? This would save a substantial amount of time trying to do this by hand.
 
Back
Top