Xcode 9 Beta 2/3 moves frameswork into project

I've had this in both Xcode 9 Beta 2 and 3.


Whenever I drag a framework into the project or use the '+' buttons to add a linked framework, Xcode moves the referenced file into the root of the project, then adds a reference into the project Navigator that refers to the original location of the framework.


I then have to go and moves the frameworks back into their original location to get the project to compile again.


I can't figure out why it's doing and can't find a way to get Xcode to behave as it should. Any ideas?

It appears that adding any file to the project in Xcode beta 2 (and just verified on beta 3) will MOVE the file into Xcode's view of the folder heirarchy, regardless of what options you select (even though there isn't anything that says "move")


I have seen this happen when you create a group from selection as well, it even creates the folder to match the group name before moving the files.


For anyone that cares at Apple, the easiest way to reproduce this is to create an empty workspace and add a file from anywhere that isn't in the same path as where the workspace is saved. The file won't be added to the workspace but it will be moved.


I have filed a bug https://bugreport.apple.com/web/?problemID=33159706

This bug is mentioned in the Xcode 9 beta release notes.


>> I have seen this happen when you create a group from selection as well, it even creates the folder to match the group name before moving the files.


If you mean a selection within the project navigator, this isn't a bug, but a new behavior in Xcode 9. Use File -> New -> Group Without Folder if you want the old behavior.

I've seen the new options when creating groups and have tried both creating groups with folders and without.


In my case I was dragging in frameworks I had downloaded from an external source ( in this case Firebase). I had already copied the frameworks into a directory inside the projects folders (ie. ./External/Firebase). Xcode would then move the framework files to the root directory of the project and create links to the ./External/Firebase/... locations which of course, would be broken.


I also encountered the same behaviour with iOS system frameworks. Thankfully though, Xcode copies these frameworks rather than moves. For example, adding Security.framework would copy the Security.framework to the root of the project and create a link in the Navigator to the original file.

This bug is mentioned in the Xcode 9 beta release notes.

Ahh thanks, I just found the changes to "Project Navigator" in the release notes and missed that when looking for this issue. I personally dislike this behavior, because I've always used "groups" in Xcode. It looks like you can detach the behavior which is nice.


I'll delete my bug.

Xcode 9 Beta 2/3 moves frameswork into project
 
 
Q