UPDATE: As of Xcode 3.2 you can rename projects from the Projects->Rename dropdown.
Earlier I had posted how to manually rename an XCode project. I have now written a BASH shell script to handle everything automatically. You can find it here.
Subscribe to:
Post Comments (Atom)
23 comments:
Thank you, thank you, THANK YOU!
Worked for me too. Thank you!
Hey Man,
You are amazing. You saved my whole day. I was trying to rename one very very big project.
Thank you very much..
// Ganesh Pisal
Cheers dude! That worked like a charm. Thanks very much! :)
I tried it, but it only works if the projectnames contain spaces. Mine did not, so there I propose a little patch.
Replace the sed for eliminating the spaces with the following code:
OLDNAMEU=${OLDNAME}
NEWNAMEU=${NEWNAME}
# create name with underscores
echo "${OLDNAME}" | grep " " > /dev/null
if [ $? -eq 0 ]; then
OLDNAMEU = `echo "${OLDNAME}" | sed -e "s/ /_/g"`
fi
echo "${NEWNAME}" | grep " " > /dev/null
if [ $? -eq 0 ]; then
NEWNAMEU = `echo "${NEWNAME}" | sed -e "s/ /_/g"`
fi
It is then doing some duplicate sedding, and grepping and finding, but that did not matter for me.
Great work and many thanks
Sebastian
@Sebastian I rename XCode projects without spaces all the time. I'm not sure why you needed to adjust something to make it work.
It works perfectly, and is a great help. Very many thanks.
This sounds amazing. I have to rename my project as I used a name containing spaces which Apple doesn't really seem to like...
How do I use your tool if my filename contains spaces?
Cause looking at your example:
renameXcodeProject.sh MyStuff MyNewStuff
a space in the first part could cause problems?
Thanks a lot!
ingo.
If your project has spaces, use quotes around the names.
./renameXcodeProject "old name" "new name"
Everything worked fine except that one of my two xib files won't load in Interface Builder.
Building target “PQR” of project “PQR” with configuration “Release” — (1 error)
cd /Users/tehZoe/Desktop/PQR
setenv PATH "/Developer3.1.3Beta5/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer3.1.3Beta5/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Developer3.1.3Beta5/usr/bin/ibtool --errors --warnings --notices --output-format human-readable-text --compile /Users/holbrook/Desktop/PQR/build/Release-iphonesimulator/PQR.app/PQRView.nib /Users/tehZoe/Desktop/PQR/PQRView.xib
/* com.apple.ibtool.errors */
Internal Error:
Description: The document "PQRView.xib" could not be opened. An instance of IBUIPQRView could not be decoded.
Recovery Suggestion: Ensure all plug-ins used to create this document have been loaded.
Build failed (1 error)
@tehZoe did you delete the build directory?
This is outstanding work! Worked perfectly, thanks.
This is awesome. Thanks a lot for doing this!
Too good !! Worked very well !! Thanks a ton for writing it :) !!
renameXcodeProject.sh is a lifesaver, thank you !
Huge thanks!!!!! You just saved me a HUGE amount of hassle.
thanks!!
Thanks mate, amazing!
work like a charm!
Hey,
completely noob question, but where do i even start with using this file?! no idea what 'Copy (this) file "renameXcodeProject.sh" to your file system, and invoke:' even means !
thanks
You do this through the terminal application of OSX. You need to know a little bit about the unix command line.
Thank you!
Just what I was looking for.
WOW!!! that is supercool, worked like charm!
I usually don't get this excited... anyway big ups!
Post a Comment