Possible Duplicate:
How can I rename a lot of files using a regex?
I've got some files named
abc-10.5.3.1-1.x86_64.rpm
abc-compiler-10.5.3.1-1.x86_64.rpm
abc-10.5.3.1-6.x86_64.rpm
abc-compiler-10.5.3.1-6.x86_64.rpm
I'd like to remove the minor version numbers (1-1 and 1-6) whenver the files are built. I can't figure out how to achieve this with the rename command on Redhat linux. The resulting filename should for example be:
abc-10.5.3.x86_64.rpm
The command doesn't take regular expressions.