Changing the name of a project

I’ve built an Automator Action for Photoshop CS5, and now I want to make a CS4 version. The actual coding is real easy, I just need to change the tell blocks to point to the older PHotoshop. Unfortunately, I named my project with CS5 in the title, so all the files have CS5 in their name, as does the Target and all that stuff. I can’t figure out how to change these to CS4 without all sorts of links breaking, and Xcode complaining about all sorts of things.

Any suggestions?

Thanks!

I’m not sure I understand the question, but If the problem is with calling Photoshop like this:

tell application "Adobe Photoshop CS5"

you could make it a bit more “generic” by using application id, like this:

tell application id "com.adobe.Photoshop"

If I remember correctly, it will target the opened Photoshop application, be it CS4, CS3 or CS5.

Is this what you meant?

Model: MacBookPro8,2
Browser: Safari 534.51.22
Operating System: Mac OS X (10.7)

Sorry, no, I’m not having any trouble calling Photoshop. The problems are all with the Project file. My filenames all start with the prefix CS5_. I could just leave them that way, and change the code to point to CS4, but I’m afraid that will get confusing later. So I’d like to rename the files, but when I do that, the project loses track of them and everything gets screwed up.

All the build parameters and everything are built around specific filenames, and the specific project name.

Oh, I see. Well, in Xcode 4 there is the Refactor command in Edit menu. I don’t know if it’ll work for AppleScriptObjC, but works fine for Obj-C. You just need to select a class name or variable inside your code and select Edit > Refactor > Rename, then enter the new name, and you can even preview the changes.

I strongly suggest making a copy of your project and testing on this copy first.

Let me know if it helps…

Wow, I never would have thought to try that. Unfortunately, when I click on the name of my Script Object, it says it has to be a class, function, or local variable, so it looks like that’s not gonna work. Thanks, though.

Yeah, as I thought, it won’t work with ASOC… Works beautifully with Objective c though. Sad they didn’t implement it for ASOC… Looks like you’re gonna have to do it manually. Sorry!

Ugh. Thanks for trying!