My project disappeared when I renamed it in git
I was putting the finishing touches on a project. One of those “finishing touches” was renaming the project. Now it’s “gone”. 😩🔫. I looked on GitHub and it’s still “there”, but I’m in over my head in terms of how to get my
master and my renamed branch to interact properly. Here’s how I got to this dreadful state:
I followed Apple’s How to Rename a Project post:
In git, from the command line, I checked out a branch to rename the project as follows:
git checkout -b rename-project
When I was done, I typed:
git add . git commit -m "Renamed my project"
Then, I went back to the master to merge the ‘rename-project` branch as follows:
git checkout master
Project /Users/me/Documents/Developer/My Renamed Project.xcodeproj cannot be opened because it is missing its project.pbxproj file.
How do I get my 2 weeks’ work back?
One Solution collect form web for “My project disappeared when I renamed it in git”
master doesn’t have your renamed project yet. Close XCode, then do
git merge rename-project
and if that succeeds, you can reopen XCode.