XCode does not save my files
I have loaded files into my project from a subdirectory named ACL. When I press save in Xcode, the file is not saved to the ACL subdirectory. If the file is saved, where is it saved to?
MacBook Pro 13″, macOS 11.5
Apple’s Worldwide Developers Conference to kick off June 10 at 10 a.m. PDT with Keynote address
The Keynote will be available to stream on apple.com, the Apple Developer app, the Apple TV app, and the Apple YouTube channel. On-demand playback will be available after the conclusion of the stream.
The Keynote will be available to stream on apple.com, the Apple Developer app, the Apple TV app, and the Apple YouTube channel. On-demand playback will be available after the conclusion of the stream.
Developer Forums relocated!
Need help with Apple Developer tools and technologies? Want to share information with other developers and Apple engineers? Visit Developer Forums at Apple.
Need help with Apple Developer tools and technologies? Want to share information with other developers and Apple engineers? Visit Developer Forums at Apple.
I have loaded files into my project from a subdirectory named ACL. When I press save in Xcode, the file is not saved to the ACL subdirectory. If the file is saved, where is it saved to?
MacBook Pro 13″, macOS 11.5
You specify where you want to save the files when you first create the Xcode project.
If you’re looking for the generated files (built apps, etc), those are stored in Xcode build directories, and those can be located accessed using the Reveal In Finder option from the Xcode menus.
I do not understand exactly what you’re doing here. Create a new project. As part of creating a new project, you will select the type of project (e.g. Swift command line tool for macOS, etc), and where you want the project created.
If you’re trying to sling random files into random Xcode project directories manually (i.e. treating Xcode like a text editor), that won’t work so well.
When adding then files through Xcode (dragging the files into the project, pasting the code into s new source module, etc), I prefer to keep all source files either in the project directory or relative to it. Which IIRC is the default.
I follow the XCode directions for creating a project. It asks for a project name, but does not ask for a project location.
I then populate the project adding files from my project subdirectory. It works fine now that I know where XCode is storing my files when I save them <command s>. Thanks for your response.
I found them! For some strange reason, XCode is saving my project files to my Documents folder instead of the folder from which I loaded the project source files! Thanks again for your help.
Xcode saves source files in the location where the Xcode project was originally opened.
I don't see any saved XCode source files anywhere on my HD. I will recreate my project (yet again) and see if that helps.
Thanks for the response!
Thanks again. I'll look into this further.
See Xcode > Preferences > Locations, and > Xcode Preferences > Locations > Derived Data > Advanced (Unique works well)
Thanks for the tip!
XCode does not save my files