Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

MMPhotog8

macrumors newbie
Original poster
Sep 9, 2009
1
0
I do all the product photography for a company. We work with a company that uses a different file naming convention. They have PFID's which look like this: 33-39477.tif while I use SKU's that look like this frt-FTBLWOO300.tif
The images we put online to our website have to have the SKU name so it links correctly. I receive hundreds of images at a time from this other company and need to quickly re-name the files from the PFID to the SKU name. I have a list of our complete inventory (roughly 23,000+) in an excel spreadsheet with column A having the PFID and column B having the sku in it. Can I use this spreadsheet to batch re-name files?

I downloaded "A Better Finder RENAME" from this website - http://www.publicspace.net/ABetterFinderRename/Manual_Rename_File_List7.html
but I am having trouble following the directions on how to use a list to re-name. Is there a better program or solution?
I want to be able to dump edited PFID files into a folder on my desktop, push a button, and have the new renamed file in another folder on the desktop. :)
 
It'll take a bit of batch magic, but should be doable. Keywords to google: CSV (comma separated values. You can save your excel document to this format), grep and rename
 
I have written a ruby script and posted it. (Ruby is installed by default on Leopard and Snow Leopard, probably Tiger).

The CSV is just a sample I made for testing, you can ignore it if you wish

I have tested it on windows and linux, as I'm not near my mac.

The beginning of the file has documentation, configuration, and usage instructions (just open it up in a text editor to view it)

If you have any other questions on it, let me know.

(If you don't like/want/need it, that's fine too)
 
File Uploaded error

I have downloaded the ruby file thats you uploaded, but i keep getting a error "does not appear to be a valid mapping" could you please advise me what I'm doing wrong

Thanks
 
I have downloaded the ruby file thats you uploaded, but i keep getting a error "does not appear to be a valid mapping" could you please advise me what I'm doing wrong

This error happens if a line in the csv file fails to have exactly two entries. It should report which line has the error.

Expected Format:
  • 33-39477.tif,FTBLWOO300.tif

Error Formats:
  • 33-39477.tif
  • 33-39477.tif,FTBLWOO300.tif,xxyyzz
  • 33-39477.tif,FTBLWOO300.tif,33-39478.tif,FTBLWOO301.tif
 
This is awesome! May I make a simple request?

I am in a similar situation where I need to rename many files in a way more complex than automator can handle.

I have hundreds of video files which I have told automator to rename the files based on their "date modified metadata" with the setting as "seconds from noon" the only problem is they are all off by 2520 seconds, and in order to matchup with my other cameras accurate time data they all need to be altered so their names are +2520 seconds.

I could bring all the names into excel and do that math quickly, then export the final list as a CSV but I don't know how to tell finder to rename all the orignals with the new names in the excel exported .csv.

Thanks!
 
Error

I tried using this on a Mac, and got the below error...help?

PFID2SKU.rb:45: syntax error, unexpected tIDENTIFIER, expecting end-of-input
require "ftools"
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.