I have a couple .pdf files with with the following:
filename_garbage.pdf
I would like to rename the files by removing the _garbage in one fell swoop to
filename.pdf
The file name is unique as is the _garbage which is also a variable length.
Ie:
123456_1.pdf
789012_1000.pdf
345678_garbage.pdf
rename to :
123456.pdf
789012.pdf
345678.pdf
I know it is a multi-step process, but so far not having any success.